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

auth error #795

Closed
zakkg3 opened this issue Apr 10, 2018 · 4 comments
Closed

auth error #795

zakkg3 opened this issue Apr 10, 2018 · 4 comments

Comments

@zakkg3
Copy link

zakkg3 commented Apr 10, 2018

Hi, i just have this error today. Didn't change anything, it was working perfectly. anyone with the same issue?
I have google auth, also tried with GitHub.. some library could change?

10/04/2018 17:19:58[D 180410 16:19:58 selector_events:65] Using selector: EpollSelector
10/04/2018 17:19:58[E 180410 16:19:58 base_events:1266] Exception in callback _auth_future_to_callback(<bound method...7f97d0680710>>)(<Future finis...e': 'Bearer'}>) at /usr/local/lib/python3.6/site-packages/tornado/auth.py:101
10/04/2018 17:19:58    handle: <Handle _auth_future_to_callback(<bound method...7f97d0680710>>)(<Future finis...e': 'Bearer'}>) at /usr/local/lib/python3.6/site-packages/tornado/auth.py:101>
10/04/2018 17:19:58    Traceback (most recent call last):
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/flower/views/auth.py", line 49, in _on_auth
10/04/2018 17:19:58        response = httpclient.HTTPClient().fetch(
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/tornado/httpclient.py", line 81, in __init__
10/04/2018 17:19:58        gen.coroutine(lambda: async_client_class(**kwargs)))
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/tornado/ioloop.py", line 577, in run_sync
10/04/2018 17:19:58        self.start()
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/tornado/platform/asyncio.py", line 112, in start
10/04/2018 17:19:58        self.asyncio_loop.run_forever()
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/asyncio/base_events.py", line 412, in run_forever
10/04/2018 17:19:58        'Cannot run the event loop while another loop is running')
10/04/2018 17:19:58    RuntimeError: Cannot run the event loop while another loop is running
10/04/2018 17:19:58
10/04/2018 17:19:58    During handling of the above exception, another exception occurred:
10/04/2018 17:19:58
10/04/2018 17:19:58    Traceback (most recent call last):
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/asyncio/events.py", line 145, in _run
10/04/2018 17:19:58        self._callback(*self._args)
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/tornado/auth.py", line 107, in _auth_future_to_callback
10/04/2018 17:19:58        callback(result)
10/04/2018 17:19:58      File "/usr/local/lib/python3.6/site-packages/flower/views/auth.py", line 53, in _on_auth
10/04/2018 17:19:58        raise tornado.web.HTTPError(403, 'Google auth failed: %s' % e)
10/04/2018 17:19:58    tornado.web.HTTPError: HTTP 403: Forbidden (Google auth failed: Cannot run the event loop while another loop is running)
10/04/2018 17:20:58[W 180410 16:20:58 auth:105] Google auth error: 
HTTPResponse(_body=None,buffer=<_io.BytesIO object at 0x7f97d0687258>,code=400,effective_url='https://www.googleapis.com/oauth2/v4/token',error=HTTP 400: Bad Request,headers=<tornado.httputil.HTTPHeaders object at 0x7f97d07d8be0>,reason='Bad Request',request=<tornado.httpclient.HTTPRequest object at 0x7f97d07d8c18>,request_time=0.04722857475280762,time_info={})
10/04/2018 17:20:58[E 180410 16:20:58 base_events:1266] Exception in callback _auth_future_to_callback(<bound method...xxxxx>>)(<Future finis...e_info={})",)>) at /usr/local/lib/python3.6/site-packages/tornado/auth.py:101
10/04/2018 17:20:58    handle: <Handle _auth_future_to_callback(<bound method...7f97d0879b38>>)(<Future finis...e_info={})",)>) at /usr/local/lib/python3.6/site-packages/tornado/auth.py:101>
10/04/2018 17:20:58    Traceback (most recent call last):
10/04/2018 17:20:58      File "/usr/local/lib/python3.6/asyncio/events.py", line 145, in _run
10/04/2018 17:20:58        self._callback(*self._args)
10/04/2018 17:20:58      File "/usr/local/lib/python3.6/site-packages/tornado/auth.py", line 107, in _auth_future_to_callback
10/04/2018 17:20:58        callback(result)
10/04/2018 17:20:58      File "/usr/local/lib/python3.6/site-packages/flower/views/auth.py", line 45, in _on_auth
10/04/2018 17:20:58        raise tornado.web.HTTPError(403, 'Google auth failed')
10/04/2018 17:20:58    tornado.web.HTTPError: HTTP 403: Forbidden (Google auth failed)
@jar349
Copy link

jar349 commented Apr 12, 2018

it's a change in tornado, it looks like: jupyter/notebook#3397

@zakkg3
Copy link
Author

zakkg3 commented May 10, 2018

Thanks @jar349

@zakkg3 zakkg3 closed this as completed May 10, 2018
@rotten
Copy link

rotten commented Feb 13, 2019

I get the event loop error shown above when I try google oauth with Tornado 5.1.1. Do we really still need to rollback to Tornado 4.5.3 ? I tried that and am getting a 403, however I'll allow that maybe something else is wrong in my config so I'll keep trying with the old tornado.

@rotten
Copy link

rotten commented Feb 13, 2019

To follow up, I didn't have the Google+ API enabled when I tried it with Tornado 4.5.3. If Google+ goes away, does that API go away too?

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

3 participants