django-disqus
django-disqus copied to clipboard
disqus_export causes HTTP Error 400: BAD REQUEST
I try to run disqus_export but it causes HTTP Error 400: BAD REQUEST. Perhaps it relates to Oauth authorization. Does django-disqus support Oauth ?
This is call stack:
Exporting 165 comment(s)
{"message":"Key could not be converted to UserKey object","code":"input-invalid","succeeded":false}
Traceback (most recent call last):
File "manage.py", line 14, in
I have the same problem playing with the client
in the shell
.
@arthurk:
In [10]: client.get_forum_list(user_api_key=settings.DISQUS_API_KEY)
http://disqus.com/api/get_forum_list/?api_version=1.1
---------------------------------------------------------------------------
HTTPError Traceback (most recent call last)
<ipython-input-10-61ba99fc5336> in <module>()
----> 1 client.get_forum_list(user_api_key=settings.DISQUS_API_KEY)
~/Proyectos/Works/kornov/lib/python3.6/site-packages/disqus/api.py in call_method(**kwargs)
59 if attr in self.METHODS:
60 def call_method(**kwargs):
---> 61 return self.call(attr, **kwargs)
62 return call_method
63 raise AttributeError
~/Proyectos/Works/kornov/lib/python3.6/site-packages/disqus/api.py in call(self, method, **params)
86 request = self._get_request(url, self.METHODS[method], **params)
87 try:
---> 88 response = urlopen(request)
89 except URLError:
90 raise
/usr/lib64/python3.6/urllib/request.py in urlopen(url, data, timeout, cafile, capath, cadefault, context)
221 else:
222 opener = _opener
--> 223 return opener.open(url, data, timeout)
224
225 def install_opener(opener):
/usr/lib64/python3.6/urllib/request.py in open(self, fullurl, data, timeout)
530 for processor in self.process_response.get(protocol, []):
531 meth = getattr(processor, meth_name)
--> 532 response = meth(req, response)
533
534 return response
/usr/lib64/python3.6/urllib/request.py in http_response(self, request, response)
640 if not (200 <= code < 300):
641 response = self.parent.error(
--> 642 'http', request, response, code, msg, hdrs)
643
644 return response
/usr/lib64/python3.6/urllib/request.py in error(self, proto, *args)
568 if http_err:
569 args = (dict, 'default', 'http_error_default') + orig_args
--> 570 return self._call_chain(*args)
571
572 # XXX probably also want an abstract factory that knows when it makes
/usr/lib64/python3.6/urllib/request.py in _call_chain(self, chain, kind, meth_name, *args)
502 for handler in handlers:
503 func = getattr(handler, meth_name)
--> 504 result = func(*args)
505 if result is not None:
506 return result
/usr/lib64/python3.6/urllib/request.py in http_error_default(self, req, fp, code, msg, hdrs)
648 class HTTPDefaultErrorHandler(BaseHandler):
649 def http_error_default(self, req, fp, code, msg, hdrs):
--> 650 raise HTTPError(req.full_url, code, msg, hdrs, fp)
651
652 class HTTPRedirectHandler(BaseHandler):
HTTPError: HTTP Error 400: BAD REQUEST