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

"Scope has changed": 'Request' object has no attribute 'GET' #49

Open
frafra opened this issue Apr 13, 2022 · 1 comment
Open

"Scope has changed": 'Request' object has no attribute 'GET' #49

frafra opened this issue Apr 13, 2022 · 1 comment

Comments

@frafra
Copy link

frafra commented Apr 13, 2022

Traceback (most recent call last):
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/ckanext/oauth2/views.py", line 58, in callback
    token = oauth2helper.get_token()
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/ckanext/oauth2/oauth2.py", line 117, in get_token
    token = oauth.fetch_token(self.token_endpoint,
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/requests_oauthlib/oauth2_session.py", line 244, in fetch_token
    self._client.parse_request_body_response(r.text, scope=self.scope)
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/clients/base.py", line 448, in parse_request_body_response
    self.token = parse_token_response(body, scope=scope)
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 441, in parse_token_response
    validate_token_parameters(params)
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 471, in validate_token_parameters
    raise w
Warning: Scope has changed from "email profile openid" to "https://www.googleapis.com/auth/userinfo.profile openid https://www.googleapis.com/auth/userinfo.email".

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/flask/app.py", line 1949, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/flask/app.py", line 1935, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/ckanext/oauth2/views.py", line 71, in callback
    error_description = toolkit.request.GET.get('error_description')
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/werkzeug/local.py", line 347, in __getattr__
    return getattr(self._get_current_object(), name)
  File "/usr/lib/ckan/venv/lib/python3.8/site-packages/werkzeug/local.py", line 347, in __getattr__
    return getattr(self._get_current_object(), name)
AttributeError: 'Request' object has no attribute 'GET'
@frafra
Copy link
Author

frafra commented Apr 19, 2022

I am testing the new Python 3/CKAN 2.9 branch, so the problem could be related to that.

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

1 participant