Запуск disqus_export в приложении django-disqus - PullRequest
0 голосов
/ 23 августа 2011

Я пытаюсь экспортировать комментарии Django в приложение django-disqus. Когда я запускаю python manage.py disqus_export --verbosity=0, я получаю следующие строки ошибок:

Traceback (most recent call last):
  File "manage.py", line 11, in <module>
    execute_manager(settings)
  File "/home/xx/webapps/xx/lib/python2.5/django/core/management/__init__.py", line 438, in execute_manager
    utility.execute()
  File "/home/xx/webapps/xx/lib/python2.5/django/core/management/__init__.py", line 379, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/home/xx/webapps/xx/lib/python2.5/django/core/management/base.py", line 191, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/home/xx/webapps/xx/lib/python2.5/django/core/management/base.py", line 220, in execute
    output = self.handle(*args, **options)
  File "/home/xx/lib/python2.5/django_disqus-0.4.1-py2.5.egg/disqus/management/commands/disqus_export.py", line 80, in handle
    forum_list = client.get_forum_list(user_api_key=settings.DISQUS_API_KEY)
  File "/home/xx/lib/python2.5/django_disqus-0.4.1-py2.5.egg/disqus/api.py", line 53, in call_method
    return self.call(attr, **kwargs)
  File "/home/xx/lib/python2.5/django_disqus-0.4.1-py2.5.egg/disqus/api.py", line 79, in call
    response = urllib2.urlopen(request)
  File "/usr/local/lib/python2.5/urllib2.py", line 124, in urlopen
    return _opener.open(url, data)
  File "/usr/local/lib/python2.5/urllib2.py", line 387, in open
    response = meth(req, response)
  File "/usr/local/lib/python2.5/urllib2.py", line 498, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/local/lib/python2.5/urllib2.py", line 425, in error
    return self._call_chain(*args)
  File "/usr/local/lib/python2.5/urllib2.py", line 360, in _call_chain
    result = func(*args)
  File "/usr/local/lib/python2.5/urllib2.py", line 506, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 400: BAD REQUEST

Смотрите здесь: http://readthedocs.org/docs/django-disqus/en/latest/commands.html#disqus-export

Однако команда --dry-run работает, поэтому я не уверен, что происходит.

1 Ответ

0 голосов
/ 23 августа 2011

Disqus может вернуть 400, если указаны неверные учетные данные.Прошло много времени с тех пор, как я посмотрел на django-disqus, но можете ли вы подтвердить, что предоставленные вами учетные данные действительны?

...