-
Notifications
You must be signed in to change notification settings - Fork 293
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
Detection of Jupyter kernels fails for Python (Microsoft Store version) #1797
Comments
Thanks for the feedback, we'll add support for the Windows Store version. |
May be related to a file system library fix in the core. |
With 2020.5.80290 the issue is still present. Should I also test it against the master branch? |
Same here.. |
I still experience the Issue with 2020.5.80290. |
Hey guys.. I just updated the extension with v2020.6.88468 |
No sorry this is not fixed yet. Sounds to me like the location on disk where we think the kernels reside are not the actual location where jupyter puts them. |
In the mean time, you might try setting this to see if it fixes your issue (we're experimenting with a new way to launch a kernel):
That will bypass jupyter and launch the kernel directly. |
Nice, with this setting finally Jupyter can run my code. thank you~ |
this trick let vscode run jupyter code, but it changes kernel spec in ipynb file, which misfunction the jupyter from command line. |
@riverscn We're rolling out this new way of launching the kernel shortly so there may be issues with it. From the ipynb file you should be able to click on the kernel in the top right to change it back to the kernel that you previously had selected, then if you run and save that it should be saved in the ipynb. Did that work for you? |
Thank you. It works. |
I found a better way: |
It works beautifully after long trial and error. Thanks a lot. ;) |
This repros if the store python is the first to install jupyter. Installing jupyter with another python first will put the kernel specs in the same location that |
When validating you'll need to:
Then the bug should repro. |
See this bug here as to why this is happening: |
hmm the only folder that I have in the Roaming folder is the Microsoft folder |
Bug: Notebook Editor, Interactive Window, Editor cells
Steps to cause the bug to occur
pip install jupyter
Actual behavior
vscode-python
fails to recognize existing kernels.The point where things start to fall apart is jupyterKernelSpec.ts#parseKernelSpecs, where the response of
jupyter kernelspec list
gets parsed. Since Python is running sandboxed (UWP), the kernel specs are NOT located in%APPDATA%\...
(as reported byjupyter kernelspec list
), but in the redirected location%LOCALAPPDATA%\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\..
.The call to
fs.fileExists
therefore returns false, resulting in a few messages likeKernel not created with the name python38264bitbb49e9738bee4bad94750749010b815e, display_name Python 3.8.2 64-bit. Output is Installed kernelspec python38264bitbb49e9738bee4bad94750749010b815e in C:\Users\stroy\AppData\Roaming\jupyter\kernels\python38264bitbb49e9738bee4bad94750749010b815e
Expected behavior
Workaround
JUPYTER_DATA_DIR
, which points to the redirected AppData folder (à laC:\Users\<User>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\Roaming\jupyter
).Your Jupyter and/or Python environment
Developer Tools Console Output
console.log
Microsoft Data Science for VS Code Engineering Team: @rchiodo, @IanMatthewHuff, @DavidKutu, @DonJayamanne, @greazer
The text was updated successfully, but these errors were encountered: