Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Github auth callback fails JSON parsing #2154

Closed
TaaviE opened this issue Nov 26, 2018 · 1 comment
Closed

Github auth callback fails JSON parsing #2154

TaaviE opened this issue Nov 26, 2018 · 1 comment

Comments

@TaaviE
Copy link

TaaviE commented Nov 26, 2018

Django-allauth version: Latest from pip

Traceback:

File "/usr/lib64/python3.7/json/decoder.py" in raw_decode
  353.             obj, end = self.scan_once(s, idx)

During handling of the above exception (2), another exception occurred:

File "~/project/.venv/lib64/python3.7/site-packages/django/core/handlers/exception.py" in inner
  34.             response = get_response(request)

File "~/project/.venv/lib64/python3.7/site-packages/django/core/handlers/base.py" in _get_response
  126.                 response = self.process_exception_by_middleware(e, request)

File "~/project/.venv/lib64/python3.7/site-packages/django/core/handlers/base.py" in _get_response
  124.                 response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "~/project/.venv/lib64/python3.7/site-packages/allauth/socialaccount/providers/oauth2/views.py" in view
  73.                 return self.dispatch(request, *args, **kwargs)

File "~/project/.venv/lib64/python3.7/site-packages/allauth/socialaccount/providers/oauth2/views.py" in dispatch
  134.                                                 response=access_token)

File "~/project/.venv/lib64/python3.7/site-packages/allauth/socialaccount/providers/github/views.py" in complete_login
  31.         extra_data = resp.json()

File "~/project/.venv/lib64/python3.7/site-packages/requests/models.py" in json
  897.         return complexjson.loads(self.text, **kwargs)

File "/usr/lib64/python3.7/json/__init__.py" in loads
  348.         return _default_decoder.decode(s)

File "/usr/lib64/python3.7/json/decoder.py" in decode
  337.         obj, end = self.raw_decode(s, idx=_w(s, 0).end())

File "/usr/lib64/python3.7/json/decoder.py" in raw_decode
  355.             raise JSONDecodeError("Expecting value", s, err.value) from None

Exception Type: JSONDecodeError at /accounts/github/login/callback/
Exception Value: Expecting value: line 3 column 1 (char 2)

Url: http://localhost:8000/accounts/github/login/callback/?code=[code]&state=[state]

@pennersr
Copy link
Owner

Closed via 88e8202

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants