Django imagekit cumulus - ResponseError: 401: Несанкционированный - PullRequest
1 голос
/ 07 ноября 2010

Это сводит меня с ума. Есть ли кто-нибудь, кто может помочь?

Traceback (последний последний вызов):

 File "/opt/python2.6/lib/python2.6/site-packages/django/core/handlers/base.py", line 92, in get_response
   response = callback(request, *callback_args, **callback_kwargs)

 File "/www/django_test1/omu2/views.py", line 26, in frontIndex
   context_instance=RequestContext(request))

 File "/opt/python2.6/lib/python2.6/site-packages/django/shortcuts/__init__.py", line 20, in render_to_response
   return HttpResponse(loader.render_to_string(*args, **kwargs), **httpresponse_kwargs)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/loader.py", line 108, in render_to_string
   return t.render(context_instance)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 178, in render
   return self.nodelist.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 779, in render
   bits.append(self.render_node(node, context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 792, in render_node
   return node.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/loader_tags.py", line 97, in render
   return compiled_parent.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 178, in render
   return self.nodelist.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 779, in render
   bits.append(self.render_node(node, context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 792, in render_node
   return node.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/loader_tags.py", line 24, in render
   result = self.nodelist.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 779, in render
   bits.append(self.render_node(node, context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 792, in render_node
   return node.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 946, in render
   autoescape=context.autoescape))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 779, in render
   bits.append(self.render_node(node, context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 792, in render_node
   return node.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/defaulttags.py", line 243, in render
   return self.nodelist_true.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 779, in render
   bits.append(self.render_node(node, context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 792, in render_node
   return node.render(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/defaulttags.py", line 155, in render
   nodelist.append(node.render(context))

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 826, in render
   output = self.filter_expression.resolve(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 546, in resolve
   obj = self.var.resolve(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 687, in resolve
   value = self._resolve_lookup(context)

 File "/opt/python2.6/lib/python2.6/site-packages/django/template/__init__.py", line 716, in _resolve_lookup
   current = getattr(current, bit)

 File "/opt/python2.6/lib/python2.6/site-packages/django_imagekit-0.3.3-py2.6.egg/imagekit/specs.py", line 94, in url
   self._create()

 File "/opt/python2.6/lib/python2.6/site-packages/django_imagekit-0.3.3-py2.6.egg/imagekit/specs.py", line 54, in _create
   if self._exists():

 File "/opt/python2.6/lib/python2.6/site-packages/django_imagekit-0.3.3-py2.6.egg/imagekit/specs.py", line 72, in _exists
   return self._obj._storage.exists(self.name)

 File "/opt/python2.6/lib/python2.6/site-packages/cumulus/storage.py", line 147, in exists
   self._get_cloud_obj(name)

 File "/opt/python2.6/lib/python2.6/site-packages/cumulus/storage.py", line 99, in _get_cloud_obj
   return self.container.get_object(name)

 File "/www/django_test1/omu2/src/python-cloudfiles/cloudfiles/utils.py", line 43, in decorator
   return f(*args, **kwargs)

 File "/www/django_test1/omu2/src/python-cloudfiles/cloudfiles/container.py", line 316, in get_object
   return Object(self, object_name, force_exists=True)

 File "/www/django_test1/omu2/src/python-cloudfiles/cloudfiles/storage_object.py", line 89, in __init__
   if not self._initialize() and force_exists:

 File "/www/django_test1/omu2/src/python-cloudfiles/cloudfiles/storage_object.py", line 468, in _initialize
   raise ResponseError(response.status, response.reason)

ResponseError: 401: Unauthorized

1 Ответ

0 голосов
/ 10 ноября 2010

Хорошо, так что я немного покопался и увлекся тем, что django-1.1.1, django-imagekit-0.3.3 и django-cumulus-0.3.3 или более ранние версии не подходят друг другу.

Я обновился до django-1.1.2 django-cumulus-0.3.4 и теперь отлично работает.

для этого выполните следующее - pip install -r <a href="http://bitbucket.org/richleland/django-cumulus/raw/0.3.4/requirements.txt" rel="nofollow">http://bitbucket.org/richleland/django-cumulus/raw/0.3.4/requirements.txt</a>

...