jupyterhub / firstuseauthenticator

JupyterHub Authenticator that lets users set passwords when they first log in
BSD 3-Clause "New" or "Revised" License
48 stars 31 forks source link

Login seems to break automatic git-pull of repo #39

Open JuanCab opened 5 years ago

JuanCab commented 5 years ago

I have a URL to a TLJH server of the form

https://SERVERNAME/hub/user-redirect/git-pull?repo=https://github.com/REPO&urlpath=apps/REPO/index.ipynb

This does a git pull of the REPO and then executes the index.ipynb notebook (via appmode package). This approach made the use the notebooks easy for our non-majors who just need to execute the notebooks, not understand their code.

I had to switch from an external OAuth authenticator (oauthenticator.auth0.Auth0OAuthenticator) to the default FirstUseAuthentication. This change was necessary because our campus' default email addresses are now too long to use for account names.

The problem is now, when a user logins, it just dumps them to the blank Jupyter notebook page instead of executing git-pull and appmode. In essence,

https://SERVERNAME/hub/user-redirect/git-pull?repo=https://github.com/REPO&urlpath=apps/REPO/index.ipynb

gets treated as

https://SERVERNAME/hub/

Any ideas why this doesn't work with the FirstUseAuthentication? Interestingly, once they are logged in, the git-pull URL works, but any attempt for a user who isn't already logged in to use it fails.

Juan

welcome[bot] commented 2 years ago

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively. welcome You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! :wave:
Welcome to the Jupyter community! :tada:

consideRatio commented 2 years ago

I transferred this issue here from the-littlest-jupyterhub distribution repo. Could it be that query parameters are truncated somewhere when using this authenticator during the login process?