Skip to content

Commit

Permalink
accept token auth on /hub/user/... which are probably requests to n…
Browse files Browse the repository at this point in the history
…on-running servers

otherwise, requests get redirected to `/hub/login` instead of failing with 404/503
  • Loading branch information
minrk committed Dec 20, 2021
1 parent 2ec722d commit 36cb1df
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions jupyterhub/handlers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1381,6 +1381,9 @@ class UserUrlHandler(BaseHandler):
Note that this only occurs if bob's server is not already running.
"""

# accept token auth for API requests that are probably to non-running servers
_accept_token_auth = True

def _fail_api_request(self, user_name='', server_name=''):
"""Fail an API request to a not-running server"""
self.log.warning(
Expand Down

0 comments on commit 36cb1df

Please sign in to comment.