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.

Content coded on vscode doesn't show saved on a jupyter notebook opened separately.

See original GitHub issue

Issue Type: Bug

Open the folder workspace where the ipynb file is. Open it to edit in Vscode. After a while open a seperate jupyter session on browser and open the same jupyter notebook being edited in vscode. Notice it’d be behind several save versions and prepare for disappointment because it now overrides vscode save and all the code is now lost. I think this is an issue in the autosave discrepancy between vscode and jupyter notebook on a browser.

Extension version: 2021.3.619093157 VS Code version: Code 1.54.2 (fd6f3bce6709b121a895d042d343d71f317d74e7, 2021-03-11T00:56:19.848Z) OS version: Windows_NT x64 10.0.18363

System Info
Item Value
CPUs Intel® Core™ i7-9850H CPU @ 2.60GHz (12 x 2592)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: enabled
opengl: enabled_on
protected_video_decode: enabled
rasterization: enabled
skia_renderer: enabled_on
video_decode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) undefined
Memory (System) 15.73GB (3.89GB free)
Process Argv –crash-reporter-id b7305d1a-d3b9-4eed-a023-f034ca814d30
Screen Reader no
VM 0%
A/B Experiments
vsliv368cf:30146710
vsreu685:30147344
python383:30185418
vspyt653:30270858
vspor879:30202332
vspor708:30202333
vspor363:30204092
vstry914:30256638
pythonvsdeb440:30248342
pythonvsded773:30248341
pythonvspyt875:30259475
dockersubset:30270708
pythontbcf:30265426
vspre833:30267464
vsdfh931:30275552

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
narbharcommented, Mar 17, 2021

@DonJayamanne I was investigating a separate issue where my jupyter session would time out with the following error:

ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host Exception in callback BaseSelectorEventLoop._read_from_self() handle: <Handle BaseSelectorEventLoop._read_from_self()> Traceback (most recent call last): File "C:\Users\bnarapar\Anaconda3\envs\env8520gpu\lib\asyncio\events.py", line 88, in _run self._context.run(self._callback, *self._args) File "C:\Users\bnarapar\Anaconda3\envs\env8520gpu\lib\asyncio\selector_events.py", line 119, in _read_from_self data = self._ssock.recv(4096)

This caused loss of kernel and leading to any data loss on executed cells. This affected VS Code too where it would say “unexpected host extension termination”. I tried searching for it online but no one ever seemed to have faced this timeout issue.

Hence to investigate it further and check if the issue was with my particular python environment, I opened the same file running in VS Code in another environment as a browser session which is where I found what happens when you do that the hard way. The issue was ultimately present across all my python environments BTW.

I reset my whole python installation via anaconda and switched to miniconda now. Looks to be holding out fine for now.

0reactions
greazercommented, Mar 22, 2021

Thanks for the feedback @narbhar; however, there’s nothing here we plan on doing to address this particular problem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

VS code opens Jupyter notebook in weird form
When a Notebook is Not Trusted, VS Code will not render Markdown cells or display the output of code cells within the Notebook....
Read more >
Working with Jupyter Notebooks in Visual Studio Code
Create, open, and save Jupyter Notebooks; Work with Jupyter code cells; View, inspect, and filter variables using the Variable Explorer and Data Viewer ......
Read more >
Jupyter notebook cannot save changes from Notebook Editor
In ~50% of VS Code sessions, I observe this behavior (multiple Notebook Editor windows even though I opened the file "once").
Read more >
Advanced Visual Studio Code for Python Developers
In this tutorial, you'll learn how you can configure, extend, and optimize Visual Studio Code for a more effective and productive Python development ......
Read more >
Jupyter Notebook 6.5.2 documentation - Read the Docs
Notebook documents: a representation of all content visible in the web application ... Jupyter doesn't send your data anywhere else—and as it's open...
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