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

Can't connect colab notebook to jupyter runtime after updating jupyter_over_ws #5152

Open
cmp1 opened this issue Jan 10, 2020 · 6 comments
Open

Comments

@cmp1
Copy link

cmp1 commented Jan 10, 2020

I recently updated jupyter_over_ws to version 0.0.7 and I am now unable to connect my colab notebook to a jupyter runtime, despite running various flags to over come this:

jupyter notebook \ --NotebookApp.allow_origin='https://colab.research.google.com' \ --port=8888 \ -- NotebookApp.disable_check_xsrf=True \ --NotebookApp.token='' \ --NotebookApp.password=''

Any idea what I am doing wrong? Typically I could overcome these issues by opening https://localhost:8888 in Chrome but that no longer does the trick.

@kevin-bates
Copy link
Member

This issue should first be diagnosed in the jupyter_http_over_ws repo. Once that is done and that analysis leads to an issue in notebook, we can take a look then. Thanks.

@cmp1
Copy link
Author

cmp1 commented Jan 10, 2020

Hi Kevin,

I have found that it is nothing to do with the jupyter_http_over_ws install. Moreover, I have found that it is due to a 'token' issue.

I currently have a password setup but despite this I am still receiving 403 'Forbidden' messages. I am unsure of how to get around this. Following the exact procedure below:

jupyter serverextension enable --py jupyter_http_over_ws

jupyter notebook \
  --NotebookApp.allow_origin='https://colab.research.google.com' \
  --port=8888 \
  --NotebookApp.port_retries=0

Opens the notebook in safari, however I am trying to run Google Colab in chrome, and when I pass the ' http://localhost:8888/' url generated by the shell I am hit with a 403 error. After having to completely reinstall Anaconda and restart the process, the shell provided me with a token with which I could pass to Colab and successfully connect to the local host, however since adding a password I am now back to square one.

If you have any workaround here I would be really grateful, as I this is a real hindrance.

@kevin-bates
Copy link
Member

Thank you for the more detailed information. This isn't my area of expertise but perhaps others have ideas. I do have a couple questions that might help troubleshoot.

  1. You imply that once you updated jupyter_http_over_ws to 0.0.7 you began having these issues. Did other aspects of your installation remain the same or did the version of Notebook also get updated? What version of Notebook are you using?

  2. Your latest comment indicates that 0.0.7 works with Safari, but not Chrome. Have you tried using an incognito window so that existing cookies, etc. are not "in play"?

  3. Have you tried reverting the extension to the previous version you were using to see if that makes a difference?

@cmp1
Copy link
Author

cmp1 commented Jan 10, 2020

Hi Kevin,

Many thanks for your help here, much appreciated.

I have actually had to go for the nuclear option of completely uninstalling and reinstalling anaconda. At time of writing, my jupyter notebook version is 6.0.1. I noticed that upon first launch, I was provided with a token that I could pass to Colab in order to connect to the runtime (which worked) but I then of course had to set a password.

Now, when i launch the same procedure the token is no longer provided, and hence Colab is prevented from connecting.

  • Your latest comment indicates that 0.0.7 works with Safari, but not Chrome. Have you tried using an incognito window so that existing cookies, etc. are not "in play"? - I have tried clearing cookies and the cache, as well as trying to connect through an incognito window but to no avail :(

  • Have you tried reverting the extension to the previous version you were using to see if that makes a difference? I have not yet - I will take a look

@cmp1
Copy link
Author

cmp1 commented Jan 10, 2020

Sadly no joy now using the previous version as I assume that everything has been updated, since I have had to reinstall Anaconda.

@cmp1
Copy link
Author

cmp1 commented Jan 10, 2020

Ok, so I have resolved the issue by simply removing the hashed password requirement from the config file. Thank you stepping in here to help Kevin. This still remains an issue however so would be useful feedback to pass onto the team.

Thanks,
Chris

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

2 participants