[ckan-dev] setting up a datastore in v1.8

Dominik Moritz dominik.moritz at okfn.org
Sun Oct 28 20:12:07 UTC 2012


Hi Kim,

the datastore extension is not a pypi package and does not have to be installed separately. It comes with core. You should be able to run `paster datastore` or `paster --plugin=ckan datastore` from the ckan root directory.

What is the output of `paster` and `paster --plugin=ckan`?

Hope that helps,
Dominik

On 28 Oct 2012, at 13:07, Kim Haklae <haklaekim at gmail.com> wrote:

> Hi,
> 
> According to instruction of the documentation, I tried to install a
> datastore using ckan v1.8.
> For setting permissions with option 1:
> 
> sudo paster datastore set-permissions SQL_SUPER_USER
> 
> this message occured:
> 
> Command 'datastore' not known (you may need to run setup.py egg_info)
> Known commands:
>  create       Create the file layout for a Python distribution
>  exe          Run #! executable files
>  help         Display help
>  make-config  Install a package and create a fresh config file/directory
>  points       Show information about entry points
>  post         Run a request for the described application
>  request      Run a request for the described application
>  serve        Serve the described application
>  setup-app    Setup an application, given a config file
> 
> In case, I tried to install a datastore extension, it also gave me an error
> as followed:
> 
> sudo -u ckandatahub /var/lib/ckan/datahub/pyenv/bin/pip install datastore
> Downloading/unpacking datastore
>  Downloading datastore-0.2.11.tar.gz
>  Running setup.py egg_info for package datastore
>    something went wrong reading the README.md file.
> Downloading/unpacking smhasher==0.136.2 (from datastore)
>  Downloading smhasher-0.136.2.tar.gz (56Kb): 56Kb downloaded
>  Running setup.py egg_info for package smhasher
> Installing collected packages: datastore, smhasher
>  Running setup.py install for datastore
>    something went wrong reading the README.md file.
>  Running setup.py install for smhasher
>    building 'smhasher' extension
>    gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
> -Wstrict-prototypes -fPIC -DMODULE_VERSION="0.136.2" -Ismhasher
> -I/usr/include/python2.6 -c smhasher.cpp -o
> build/temp.linux-i686-2.6/smhasher.o
>    cc1plus: warning: command line option "-Wstrict-prototypes" is valid
> for Ada/C/ObjC but not for C++
>    smhasher.cpp:11:20: error: Python.h: No such file or directory
>    smhasher.cpp:22: error: expected initializer before ‘*’ token
>    error: command 'gcc' failed with exit status 1
>    Complete output from command /var/lib/ckan/datahub/pyenv/bin/python -c
> "import
> setuptools;__file__='/var/lib/ckan/datahub/pyenv/build/smhasher/setup.py';exec(compile(open(__file__).read().replace('\r\n',
> '\n'), __file__, 'exec'))" install --single-version-externally-managed
> --record /tmp/pip-Gud_TS-record/install-record.txt --install-headers
> /var/lib/ckan/datahub/pyenv/include/site/python2.6:
>    running install
> 
> running build
> 
> running build_ext
> 
> building 'smhasher' extension
> 
> creating build
> 
> creating build/temp.linux-i686-2.6
> 
> creating build/temp.linux-i686-2.6/smhasher
> 
> gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
> -Wstrict-prototypes -fPIC -DMODULE_VERSION="0.136.2" -Ismhasher
> -I/usr/include/python2.6 -c smhasher.cpp -o
> build/temp.linux-i686-2.6/smhasher.o
> 
> cc1plus: warning: command line option "-Wstrict-prototypes" is valid for
> Ada/C/ObjC but not for C++
> 
> smhasher.cpp:11:20: error: Python.h: No such file or directory
> 
> smhasher.cpp:22: error: expected initializer before ‘*’ token
> 
> error: command 'gcc' failed with exit status 1
> 
> ----------------------------------------
> Command /var/lib/ckan/datahub/pyenv/bin/python -c "import
> setuptools;__file__='/var/lib/ckan/datahub/pyenv/build/smhasher/setup.py';exec(compile(open(__file__).read().replace('\r\n',
> '\n'), __file__, 'exec'))" install --single-version-externally-managed
> --record /tmp/pip-Gud_TS-record/install-record.txt --install-headers
> /var/lib/ckan/datahub/pyenv/include/site/python2.6 failed with error code 1
> Storing complete log in /home/haklaekim/.pip/pip.log
> Traceback (most recent call last):
>  File "/var/lib/ckan/datahub/pyenv/bin/pip", line 9, in <module>
>    load_entry_point('pip==1.0.2', 'console_scripts', 'pip')()
>  File
> "/var/lib/ckan/datahub/pyenv/lib/python2.6/site-packages/pip-1.0.2-py2.6.egg/pip/__init__.py",
> line 116, in main
>    return command.main(initial_args, args[1:], options)
>  File
> "/var/lib/ckan/datahub/pyenv/lib/python2.6/site-packages/pip-1.0.2-py2.6.egg/pip/basecommand.py",
> line 151, in main
>    log_fp = open_logfile(log_fn, 'w')
>  File
> "/var/lib/ckan/datahub/pyenv/lib/python2.6/site-packages/pip-1.0.2-py2.6.egg/pip/basecommand.py",
> line 177, in open_logfile
>    os.makedirs(dirname)
>  File "/var/lib/ckan/datahub/pyenv/lib/python2.6/os.py", line 157, in
> makedirs
>    mkdir(name, mode)
> OSError: [Errno 13] Permission denied: '/home/haklaekim/.pip'
> 
> Thanks in advance.
> 
> - Haklae
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev/dominik.moritz%40okfn.org





More information about the ckan-dev mailing list