question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Local vs Remote is not obvious

See original GitHub issue

Applies To

  • Notebooks (.ipynb files)
  • Interactive Window and/or Cell Scripts (.py files with #%% markers)

What happened?

Hi bros,

I got a issue, steps to reproduce as below:

Result: Colab connect runtime to local jupyter server successfully. Vscode can’t connect local jupyter server.

Thanks in advanced for your help!

VS Code Version

1.68.1(user setup)

Jupyter Extension Version

v2022.6.1001631011

Jupyter logs

info 22:43:52.812: Creating server with url : http://localhost:8888/
info 22:43:53.3: Checking for server existence.
info 22:43:53.8: Checking for server usability.
info 22:43:53.8: Starting notebook server.
info 22:43:53.9: Connecting to server
info 22:43:53.11: Connecting to process server
info 22:43:53.11: Connecting server kernel http://localhost:8888/
Connecting to Jupyter server at http://localhost:8888/
info 22:43:53.11: Creating server with url : http://localhost:8888/
info 22:43:53.16: Connection complete server
info 22:43:53.18: Server started.
info 22:43:53.18: Creating server with url : http://localhost:8888/
info 22:43:53.169: Creating server with url : http://localhost:8888/
info 22:44:15.867: Loading webview. View is notset
info 22:44:15.869: Loading web view...
info 22:44:15.870: Webview panel created.
info 22:44:16.143: Web view react rendered

Jupyter server logs (Window cmd)

jupyter notebook --NotebookApp.allow_origin='https://colab.research.google.com' --port=8888 --NotebookApp.port_retries=0
jupyter_http_over_ws extension initialized. Listening on /http_over_websocket
[W 2022-06-22 21:49:53.045 LabApp] 'allow_origin' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[W 2022-06-22 21:49:53.045 LabApp] 'port' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[W 2022-06-22 21:49:53.045 LabApp] 'port_retries' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[W 2022-06-22 21:49:53.045 LabApp] 'port_retries' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[I 2022-06-22 21:49:53.045 LabApp] JupyterLab extension loaded from C:\Users\MSI GAMING\AppData\Local\Programs\Python\Python38\lib\site-packages\jupyterlab
[I 2022-06-22 21:49:53.045 LabApp] JupyterLab application directory is C:\Users\MSI GAMING\AppData\Local\Programs\Python\Python38\share\jupyter\lab
[I 21:49:53.045 NotebookApp] Serving notebooks from local directory: C:\Users\MSI GAMING\.jupyter
[I 21:49:53.045 NotebookApp] Jupyter Notebook 6.4.12 is running at:
[I 21:49:53.045 NotebookApp] http://localhost:8888/?token=0c35085c94c0f1bf98975d9fe8ecdf9662f5a808f5f487da
[I 21:49:53.045 NotebookApp]  or http://127.0.0.1:8888/?token=0c35085c94c0f1bf98975d9fe8ecdf9662f5a808f5f487da
[I 21:49:53.045 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 21:49:53.092 NotebookApp]

    To access the notebook, open this file in a browser:
        file:///C:/Users/MSI%20GAMING/AppData/Roaming/jupyter/runtime/nbserver-8248-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/?token=0c35085c94c0f1bf98975d9fe8ecdf9662f5a808f5f487da
     or http://127.0.0.1:8888/?token=0c35085c94c0f1bf98975d9fe8ecdf9662f5a808f5f487da
[W 21:50:07.022 NotebookApp] Forbidden
[W 21:50:07.022 NotebookApp] 403 GET /api/kernels?1655909407020 (127.0.0.1) 1.000000ms referer=None
[W 21:50:19.775 NotebookApp] Forbidden
[W 21:50:19.776 NotebookApp] 403 GET /api/kernelspecs?1655909419773 (127.0.0.1) 1.010000ms referer=None
[W 21:50:36.673 NotebookApp] Forbidden
[W 21:50:39.017 NotebookApp] 403 GET /api/sessions?1655909436673 (127.0.0.1) 2344.740000ms referer=None

Coding Language and Runtime Version

Python 3.8.8 64-bit

Language Extension Version (if applicable)

v2022.8.0

Anaconda Version (if applicable)

Pip 22.1.2 instead

Running Jupyter locally or remotely?

Local

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:15 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
rchiodocommented, Jun 23, 2022

#10435 should address this problem.

1reaction
rchiodocommented, Jun 22, 2022

The general problem of ‘local’ vs ‘remote’ not being clear is something on our radar though. Some ideas are here: https://github.com/microsoft/vscode-jupyter/issues/10363 https://github.com/microsoft/vscode-jupyter/issues/10435

Read more comments on GitHub >

github_iconTop Results From Across the Web

Remote Work vs Local Work: Which Gets the Job Done?
Remote work has lately become less a trend and more a necessity. We examine the pros and cons of remote work vs local...
Read more >
Hiring Local vs. Remote: Pros & Cons of a Distributed Workforce
One of the main reasons companies consider outsourcing or hiring remote employees in the first place is the clear cost-benefit. Some of the...
Read more >
Word for whether something is local or remote
That is, whether or not an action is local or remote, a name for that distinction. For example, "the ____ of the 'delete'...
Read more >
What is the difference between local chains and remote chanins
Local chains are showing the signal of the device that you are logged into, while the remote chains are the signal of the...
Read more >
Git: distinguish between local and remote tags - Stack Overflow
... I suggest this is that there's not an obvious way to tell the difference between a tag that was created locally and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found