You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running this code inside the paster shell with the full CKAN environment loaded, the same command works.
Here is a stack trace:
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/ckanapi/localckan.py", line 44, in call_action
return self._get_action(action)(dict(context), dict(data_dict))
File "/source/virtualenv/statscan2/src/ckan/ckan/logic/init.py", line 329, in wrapped
return _action(context, data_dict, **kw)
File "/source/virtualenv/statscan2/src/ckan/ckan/logic/init.py", line 386, in wrapper
return action(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/logic/action.py", line 277, in datastore_search
result = db.search(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 1124, in search
return search_data(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 930, in search_data
_insert_links(data_dict, limit, offset)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 837, in _insert_links
if not toolkit.request.environ:
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/paste/registry.py", line 137, in getattr
return getattr(self._current_obj(), attr)
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/paste/registry.py", line 197, in _current_obj
'thread' % self.__name)
TypeError: No object (name: request) has been registered for this thread
Any ideas?
The text was updated successfully, but these errors were encountered:
try:
local = ckanapi.LocalCKAN()
local.action.datastore_search(resource_id = '...')
same call works when RemoteCKAN() is used with a valid api key
This seems to happen when the call is executed as part of a Paste command. (example: https://github.com/deniszgonjanin/ckanext-recombinant/blob/master/ckanext/recombinant/commands.py#L31)
When running this code inside the paster shell with the full CKAN environment loaded, the same command works.
Here is a stack trace:
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/ckanapi/localckan.py", line 44, in call_action
return self._get_action(action)(dict(context), dict(data_dict))
File "/source/virtualenv/statscan2/src/ckan/ckan/logic/init.py", line 329, in wrapped
return _action(context, data_dict, **kw)
File "/source/virtualenv/statscan2/src/ckan/ckan/logic/init.py", line 386, in wrapper
return action(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/logic/action.py", line 277, in datastore_search
result = db.search(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 1124, in search
return search_data(context, data_dict)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 930, in search_data
_insert_links(data_dict, limit, offset)
File "/source/virtualenv/statscan2/src/ckan/ckanext/datastore/db.py", line 837, in _insert_links
if not toolkit.request.environ:
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/paste/registry.py", line 137, in getattr
return getattr(self._current_obj(), attr)
File "/source/virtualenv/statscan2/lib/python2.6/site-packages/paste/registry.py", line 197, in _current_obj
'thread' % self.__name)
TypeError: No object (name: request) has been registered for this thread
Any ideas?
The text was updated successfully, but these errors were encountered: