[ckan-dev] CKAN 1.8 Install datastore errors

Isabel Ruiz isaruizmellado at gmail.com
Thu Apr 25 12:40:36 UTC 2013


Hi!

First of all: Please excuse my limited English.

This is my configuration:

* CKAN 1.8 installed on Virtual Machine VMWare Ubuntu
* PostgreSQL version 9.1.9 in another Linux machine, but not virtualized.

Everythings works. I can insert datasets, upload files.

Now I need insert datastore.

I follow http://docs.ckan.org/en/ckan-1.8/datastore-setup.html steps

But It doesn't work.

If I run paster, I cannot use datastorer:

*$ paster --plugin=ckan
Usage: /usr/bin/paster COMMAND
Usage: paster [paster_options] COMMAND [command_options]

Options:
  --version         show program's version number and exit
  --plugin=PLUGINS  Add a plugin to the list of commands (plugins are Egg
                    specs; will also require() the Egg)
  -h, --help        Show this help message

Commands:
  create            Create the file layout for a Python distribution
  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

ckan:
  celeryd           Celery daemon
  check-po-files    Check po files for common mistakes
  create-test-data  Create test data in the database.
  dataset           Manage datasets
  datastore         Perform commands to set up the datastore.
  db                Perform various tasks on the database.
  notify            Send out modification notifications.
  plugin-info        Provide info on installed plugins.
  profile           Code speed profiler
  ratings           Manage the ratings stored in the db
  rdf-export
  rights            Commands relating to per-object and system-wide access
rights.
  roles             Commands relating to roles and actions.
  search-index      Creates a search index for all datasets
  sysadmin          Gives sysadmin rights to a named user
  tracking          Update tracking statistics
  user              Manage users
*

Then I try install and run test available in
https://github.com/okfn/ckanext-datastorer and It returns two errors:

*$ sudo nosetests
/var/lib/ckan/ckan/pyenv/src/ckanext-datastorer/ckanext/datastorer/tests
/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/plugins/manager.py:395:
RuntimeWarning: Unable to load plugin sqlalchemy =
sqlalchemy.test.noseplugin:NoseSQLAlchemy: No module named test.noseplugin
  RuntimeWarning)
EE
======================================================================
ERROR: Failure: ImportError (No module named flask)
----------------------------------------------------------------------
Traceback (most recent call last):
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/loader.py",
line 413, in loadTestsFromName
    addr.filename, addr.module)
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/importer.py",
line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/importer.py",
line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File
"/var/lib/ckan/ckan/pyenv/src/ckanext-datastorer/ckanext/datastorer/tests/static_files_server.py",
line 1, in <module>
    from flask import Flask
ImportError: No module named flask

======================================================================
ERROR: Failure: ImportError (No module named datastorer.tasks)
----------------------------------------------------------------------
Traceback (most recent call last):
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/loader.py",
line 413, in loadTestsFromName
    addr.filename, addr.module)
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/importer.py",
line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File
"/usr/local/lib/python2.6/dist-packages/nose-1.3.0-py2.6.egg/nose/importer.py",
line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File
"/var/lib/ckan/ckan/pyenv/src/ckanext-datastorer/ckanext/datastorer/tests/test_upload_basic.py",
line 1, in <module>
    import ckanext.datastorer.tasks as tasks
ImportError: No module named datastorer.tasks

----------------------------------------------------------------------
Ran 2 tests in 0.053s

FAILED (errors=2)
*
Finally I try create a new datastore manually, I use your example and It
works and I can see this datasource in my ckan:

*curl -X POST http://est50v:5000/api/3/action/datastore_create -H
"Authorization:WRITE-MY-AUTHORITATION-KEY" -d '{"resource_id":
"WRITE-MY-RESOURCE-ID", "fields": [ {"id": "a"}, {"id": "b"} ], "records":
[ { "a": 1, "b": "xyz"}, {"a": 2, "b": "zzz"} ]}'
*

Can you guide me? I dont know what else can I do?

Thanks!!!!


-- 
Isabel M. Ruiz Mellado
http://about.me/isabelruiz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20130425/e3596812/attachment.html>


More information about the ckan-dev mailing list