[ckan-dev] Ckanext-storage configuration issue
Flavio Coelho
fccoelho at gmail.com
Sat Jun 4 15:20:14 UTC 2011
Hi,
I finally got around to test ckanext-storage with local filesystem storage .
I found the docs weren't clear enough about what should go in the config
variable "ckanext.storage.bucket", tried a string and I am getting the
error below.
what am I doing wrong?
thanks in advance, Flávio
---------- Forwarded message ----------
From: <paste at localhost>
Date: Sat, Jun 4, 2011 at 10:14
Subject: WebApp Error: <class
'pairtree.storage_exceptions.NotAPairtreeStoreException'>:
To: fccoelho at fgv.br
URL: http://ckan.emap.fgv.br/storage/upload
Module weberror.errormiddleware:*162* in __call__
<< <#1305b388182ca972_> __traceback_supplement__ = Supplement,
self, environ
sr_checker = ResponseStartChecker(start_response)
app_iter = self.application(environ, sr_checker)
return self.make_catching_iter(app_iter, environ,
sr_checker)
except:
>> <#1305b388182ca972_>app_iter = self.application(environ, sr_checker)
Module beaker.middleware:*73* in __call__
<< <#1305b388182ca972_>
self.cache_manager)
environ[self.environ_key] = self.cache_manager
return self.app(environ, start_response)
>> <#1305b388182ca972_>return self.app(environ, start_response)
Module beaker.middleware:*152* in __call__
<< <#1305b388182ca972_> headers.append(('Set-cookie'
, cookie))
return start_response(status, headers, exc_info)
return self.wrap_app(environ, session_start_response)
def _get_session(self):
>> <#1305b388182ca972_>return self.wrap_app(environ, session_start_response
)
Module routes.middleware:*130* in __call__
<< <#1305b388182ca972_> environ['SCRIPT_NAME'] = environ[
'SCRIPT_NAME'][:-1]
response = self.app(environ, start_response)
# Wrapped in try as in rare cases the attribute will be gone
already
>> <#1305b388182ca972_>response = self.app(environ, start_response)
Module pylons.wsgiapp:*124* in __call__
<< <#1305b388182ca972_> return ['%s' % paste.registry.
restorer.get_request_id(environ)]
controller = self.resolve(environ, start_response)
response = self.dispatch(controller, environ, start_response)
>> <#1305b388182ca972_>controller = self.resolve(environ, start_response)
Module pylons.wsgiapp:*263* in resolve
<< <#1305b388182ca972_> if self.log_debug:
log.debug("Resolved URL to controller: %r", controller)
return self.find_controller(controller)
def find_controller(self, controller):
>> <#1305b388182ca972_>return self.find_controller(controller)
Module ckan.config.environment:*39* in find_controller
<< <#1305b388182ca972_> # Check to see if its a dotted name
if '.' in controller or ':' in controller:
mycontroller = pkg_resources.EntryPoint.parse('x=%s' %
controller).load(False)
self.controller_classes[controller] = mycontroller
return mycontroller
>> <#1305b388182ca972_>mycontroller = pkg_resources.EntryPoint.parse('x=%s'
% controller).load(False)
Module pkg_resources:*1954* in load
<< <#1305b388182ca972_> def load(self, require=True, env=None, installer
=None):
if require: self.require(env, installer)
entry = __import__(self.module_name, globals(),globals(), [
'__name__'])
for attr in self.attrs:
try:
>> <#1305b388182ca972_>entry = __import__(self.module_name, globals(),
globals(), ['__name__'])
Module ?:*87* in <module>
<< <#1305b388182ca972_>class StorageAPIController(BaseController):
ofs = get_ofs()
>> <#1305b388182ca972_>class StorageAPIController(BaseController):
Module ?:*88* in StorageAPIController
<< <#1305b388182ca972_>class StorageAPIController(BaseController):
ofs = get_ofs()
@jsonpify
>> <#1305b388182ca972_>ofs = get_ofs()
Module ?:*69* in get_ofs
<< <#1305b388182ca972_> continue
kw[k[4:]] = v
ofs = get_impl(storage_backend)(**kw)
return ofs
>> <#1305b388182ca972_>ofs = get_impl(storage_backend)(**kw)
Module ofs.local.pairtreestore:*26* in __init__
<< <#1305b388182ca972_> self.hashing_type = hashing_type
self.shorty_length = shorty_length
self._open_store()
def _open_store(self):
>> <#1305b388182ca972_>self._open_store()
Module ofs.local.pairtreestore:*30* in _open_store
<< <#1305b388182ca972_> def _open_store(self):
if self.hashing_type:
self._store = PairtreeStorageClient(self.uri_base, self.
storage_dir, shorty_length=self.shorty_length, hashing_type=self.
hashing_type)
else:
self._store = PairtreeStorageClient(self.uri_base, self.
storage_dir, shorty_length=shorty_length)
>> <#1305b388182ca972_>self._store = PairtreeStorageClient(self.uri_base,
self.storage_dir, shorty_length=self.shorty_length, hashing_type=self.
hashing_type)
Module pairtree.pairtree_client:*91* in __init__
<< <#1305b388182ca972_> self._decode = re.compile(r"\^(..)", re.U)
self._init_store()
def __char2hex(self, m):
>> <#1305b388182ca972_>self._init_store()
Module pairtree.pairtree_client:*264* in _init_store
<< <#1305b388182ca972_> self.uri_base = prefix
else:
raise NotAPairtreeStoreException
if not os.path.isdir(self.store_dir):
>> <#1305b388182ca972_>raise NotAPairtreeStoreException
*NotAPairtreeStoreException: *
CGI Variables AUTH_TYPE 'cookie' DOCUMENT_ROOT '/etc/apache2/htdocs'
GATEWAY_INTERFACE 'CGI/1.1' HTTP_ACCEPT
'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
HTTP_ACCEPT_CHARSET 'ISO-8859-1,utf-8;q=0.7,*;q=0.7'
HTTP_ACCEPT_ENCODING 'gzip,
deflate' HTTP_ACCEPT_LANGUAGE 'pt-br,pt;q=0.8,en-us;q=0.5,en;q=0.3'
HTTP_CACHE_CONTROL 'max-age=0' HTTP_CONNECTION 'keep-alive'
HTTP_COOKIE '__utma=4669863.1260802706.1295364409.1306935693.1306960483.86;
__utmz=4669863.1295364409.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none);
SESS61faf7f7d2406929b2f9eb4cbfff17d2=a3306f5d1194cf0d8a51dbf7b42c1259;
ckan=d4951177ef995d92f0f987d481bd9180aa0f89e4518921db9cd9b6ac75fdd3fab4a25d06;
auth_tkt="c6c3c3e0b3fe7bb765356659992760b24da43221flavio!userid_type:unicode";
auth_tkt="c6c3c3e0b3fe7bb765356659992760b24da43221flavio!userid_type:unicode";
ckan_user="flavio"; ckan_display_name="Fl\xc3\xa1vio Code\xc3\xa7o Coelho";
ckan_apikey="c139718d-918f-4a2b-b219-e33cb05cbe23"; __utmc=4669863'
HTTP_HOST 'ckan.emap.fgv.br' HTTP_KEEP_ALIVE '115' HTTP_USER_AGENT 'Mozilla/5.0
(X11; Linux x86_64; rv:2.0.1) Gecko/20100101 Firefox/4.0.1' PATH_INFO
'/storage/upload' PATH_TRANSLATED '/home/flavio/var/srvc/
ckan.emap.fgv.br/pyenv/bin/ckan.emap.fgv.br.py/storage/upload' REMOTE_ADDR
'10.250.48.110' REMOTE_PORT '45873' REMOTE_USER u'flavio' REMOTE_USER_DATA
'userid_type:unicode' REMOTE_USER_TOKENS [''] REQUEST_METHOD 'GET'
REQUEST_URI '/storage/upload' SCRIPT_FILENAME '/home/flavio/var/srvc/
ckan.emap.fgv.br/pyenv/bin/ckan.emap.fgv.br.py' SERVER_ADDR '10.252.2.60'
SERVER_ADMIN '[no address given]' SERVER_NAME 'ckan.emap.fgv.br' SERVER_PORT
'80' SERVER_PROTOCOL 'HTTP/1.1' SERVER_SIGNATURE '<address>Apache/2.2.16
(Debian) Server at ckan.emap.fgv.br Port 80</address>\n'
SERVER_SOFTWARE 'Apache/2.2.16
(Debian)' WSGI Variables application <beaker.middleware.CacheMiddleware
object at 0x7f224f6edcd0> beaker.cache <beaker.cache.CacheManager object at
0x7f224f6edd90> beaker.get_session <bound method
SessionMiddleware._get_session of <beaker.middleware.SessionMiddleware
object at 0x7f224f6edd10>> beaker.session {'locale': u'pt_BR',
'_accessed_time': 1307200450.575073, '_creation_time': 1302605470.0245121}
mod_wsgi.application_group 'dck093|' mod_wsgi.callable_object 'application'
mod_wsgi.handler_script '' mod_wsgi.input_chunked '0' mod_wsgi.listener_host
'' mod_wsgi.listener_port '80' mod_wsgi.process_group 'ckan'
mod_wsgi.request_handler 'wsgi-script' mod_wsgi.script_reloading '1'
mod_wsgi.version (3, 3) paste.cookies (<SimpleCookie:
SESS61faf7f7d2406929b2f9eb4cbfff17d2='a3306f5d1194cf0d8a51dbf7b42c1259'
__utma='4669863.1260802706.1295364409.1306935693.1306960483.86'
__utmc='4669863'
__utmz='4669863.1295364409.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none)'
auth_tkt='c6c3c3e0b3fe7bb765356659992760b24da43221flavio!userid_type:unicode'
ckan='d4951177ef995d92f0f987d481bd9180aa0f89e4518921db9cd9b6ac75fdd3fab4a25d06'
ckan_apikey='c139718d-918f-4a2b-b219-e33cb05cbe23'
ckan_display_name='Fl\xc3\xa1vio Code\xc3\xa7o Coelho' ckan_user='flavio'>,
'__utma=4669863.1260802706.1295364409.1306935693.1306960483.86;
__utmz=4669863.1295364409.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none);
SESS61faf7f7d2406929b2f9eb4cbfff17d2=a3306f5d1194cf0d8a51dbf7b42c1259;
ckan=d4951177ef995d92f0f987d481bd9180aa0f89e4518921db9cd9b6ac75fdd3fab4a25d06;
auth_tkt="c6c3c3e0b3fe7bb765356659992760b24da43221flavio!userid_type:unicode";
auth_tkt="c6c3c3e0b3fe7bb765356659992760b24da43221flavio!userid_type:unicode";...
__utmc=4669863') paste.registry <paste.registry.Registry object at
0x7f224f8dad50> paste.throw_errors True pylons.environ_config {'session':
'beaker.session', 'cache': 'beaker.cache'} pylons.pylons
<pylons.util.PylonsContext
object at 0x7f224fa58510> pylons.routes_dict {'action': u'index',
'controller': u'ckanext.storage.controller:StorageController'}
repoze.who.identity <repoze.who identity (hidden, dict-like) at
139785342188544> repoze.who.logger <logging.Logger instance at
0x7f224f6eab48> repoze.who.plugins {'openid': <OpenIdIdentificationPlugin
139785340260752>, 'friendlyform': <FriendlyFormPlugin 139785338280784>,
'ckan.lib.authenticator:UsernamePasswordAuthenticator':
<ckan.lib.authenticator.UsernamePasswordAuthenticator object at
0x7f224f8daa50>, 'auth_tkt': <AuthTktCookiePlugin 139785340260880>,
'ckan.lib.authenticator:OpenIDAuthenticator':
<ckan.lib.authenticator.OpenIDAuthenticator object at 0x7f224f8da4d0>}
routes.route <routes.route.Route object at 0x7f224f5ab090> routes.url
<routes.util.URLGenerator
object at 0x7f224f8dae10> webob._parsed_query_vars (GET([]), '')
webob.adhoc_attrs {'language': 'en-us'} wsgi process 'Multi process AND
threads (?)' wsgi.file_wrapper <built-in method file_wrapper of
mod_wsgi.Adapter object at 0x7f224c8aaeb8> wsgi.version (1, 1)
wsgiorg.routing_args (<routes.util.URLGenerator object at 0x7f224f8dae10>,
{'action': u'index', 'controller':
u'ckanext.storage.controller:StorageController'})
--
Flávio Codeço Coelho
================
+55(21) 3799-5567
Professor
Escola de Matemática Aplicada
Fundação Getúlio Vargas
Rio de Janeiro - RJ
Brasil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20110604/3ea44a5d/attachment.html>
More information about the ckan-dev
mailing list