You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 2464, in call
return self.wsgi_app(environ, start_response)
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 2450, in wsgi_app
response = self.handle_exception(e)
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1867, in handle_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.6/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 2447, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1952, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1821, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.6/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1950, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1936, in dispatch_request
return self.view_functionsrule.endpoint
File "/usr/local/lib/python3.6/site-packages/flask_appbuilder/security/views.py", line 681, in oauth_authorized
resp = self.appbuilder.sm.oauth_remotes[provider].authorize_access_token()
File "/usr/local/lib/python3.6/site-packages/authlib/integrations/flask_client/remote_app.py", line 74, in authorize_access_token
params = self.retrieve_access_token_params(flask_req, request_token)
File "/usr/local/lib/python3.6/site-packages/authlib/integrations/base_client/base_app.py", line 138, in retrieve_access_token_params
params = self.framework.generate_access_token_params(self.request_token_url, request)
File "/usr/local/lib/python3.6/site-packages/authlib/integrations/flask_client/integration.py", line 38, in generate_access_token_params
'code': request.args['code'],
File "/usr/local/lib/python3.6/site-packages/werkzeug/datastructures.py", line 442, in getitem
raise exceptions.BadRequestKeyError(key)
werkzeug.exceptions.BadRequestKeyError: 400 Bad Request: The browser (or proxy) sent a request that this server could not understand.
KeyError: 'code'
The text was updated successfully, but these errors were encountered:
Issue-Label Bot is automatically applying the label #bug to this issue, with a confidence of 0.94. Please mark this comment with 👍 or 👎 to give our bot feedback!
We have been using OAuth provider feature for a while now
I tried upgrading to the upcoming release 0.37 and found that the feature is now broken
Expected results
sign in should redirect to provider actual login page
Actual results
we get 400 response code and an internal exception
what actually happens.
Screenshots
How to reproduce the bug
Environment
(please complete the following information):
0.37
3.6
node -v
npm -v
Checklist
Make sure these boxes are checked before submitting your issue - thank you!
Additional context
Logs when clicking on login button:
superset_1 | DEBUG:flask_appbuilder.security.views:Provider: okta
superset_1 | DEBUG:flask_appbuilder.security.views:Going to call authorize for: okta
superset_1 | DEBUG:authlib.integrations.base_client.base_app:Saving authorize data: {'redirect_uri': 'https://localhost:8088/oauth-authorized/okta', 'url': 'https://.okta.com/oauth2/default/v1/authorize?response_type=code&client_id=None&redirect_uri=https%3A%2F%2Flocalhost%3A8088%2Foauth-authorized%2Fokta&state=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJuZXh0IjpbIiJdfQ.fdfto7RZFzoca-BIwMaXI9t-jsGjhSPMH_ltWoj85-Y', 'state': 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJuZXh0IjpbIiJdfQ.fdfto7RZFzoca-BIwMaXI9t-jsGjhSPMH_ltWoj85-Y'}
when loading in browser the following link: https://localhost:8088/oauth-authorized/okta
The text was updated successfully, but these errors were encountered: