Closed leonarduschen closed 4 years ago
Hello, I'm having a similar issue. It happens with any kernel I try to choose. Attaching a dev console log -1598962107726.log
Hello, almost the same issue:
Unable to start session for kernel Python 3.8.5 32-bit. Select another kernel to launch with.
Version: 1.48.2 (user setup) Commit: a0479759d6e9ea56afa657e454193f72aef85bd0 Date: 2020-08-25T10:13:11.295Z Electron: 7.3.2 Chrome: 78.0.3904.130 Node.js: 12.8.1 V8: 7.8.279.23-electron.0 OS: Windows_NT x64 6.3.9600
upd:
appdirs 1.4.4 argon2-cffi 20.1.0 astroid 2.4.2 attrs 20.1.0 autopep8 1.5.4 backcall 0.2.0 black 19.3b0 bleach 3.1.5 certifi 2020.6.20 cffi 1.14.2 chardet 3.0.4 click 7.1.2 colorama 0.4.3 cycler 0.10.0 decorator 4.4.2 defusedxml 0.6.0 docutils 0.16 entrypoints 0.3 idna 2.10 ipykernel 5.3.4 ipython 7.18.1 ipython-genutils 0.2.0 ipywidgets 7.5.1 isort 5.4.2 jedi 0.17.2 Jinja2 2.11.2 joblib 0.16.0 jsonschema 3.2.0 jupyter 1.0.0 jupyter-client 6.1.7 jupyter-console 6.2.0 jupyter-core 4.6.3 kiwisolver 1.2.0 lazy-object-proxy 1.5.1 MarkupSafe 1.1.1 matplotlib 3.3.1 mccabe 0.6.1 mistune 0.8.4 mpmath 1.1.0 nbconvert 5.6.1 nbformat 5.0.7 notebook 6.1.3 numpy 1.19.1 packaging 20.4 pandas 1.1.1 pandocfilters 1.4.2 parso 0.8.0 pickleshare 0.7.5 Pillow 7.2.0 pip 20.2.2 plotly 4.9.0 prometheus-client 0.8.0 prompt-toolkit 3.0.7 pycodestyle 2.6.0 pycparser 2.20 pycryptodome 3.9.8 Pygments 2.6.1 pylint 2.6.0 pyparsing 2.4.7 pyrsistent 0.16.0 python-dateutil 2.8.1 pytz 2020.1 pywin32 228 pywinpty 0.5.7 pyzmq 19.0.2 qtconsole 4.7.6 QtPy 1.9.0 requests 2.24.0 retrying 1.3.3 rstcheck 3.3.1 scikit-learn 0.23.2 scipy 1.5.2 Send2Trash 1.5.0 setuptools 50.0.0 simple-crypt 4.1.7 six 1.15.0 sklearn 0.0 terminado 0.8.3 testpath 0.4.4 threadpoolctl 2.1.0 toml 0.10.1 tornado 6.0.4 traitlets 5.0.0 urllib3 1.25.10 wcwidth 0.2.5 webencodings 0.5.1 widgetsnbextension 3.5.1 wrapt 1.12.1
Similar issue with Python 3.8.5 64-bit, not using venv output.txt
There is a workaround, you can use dependencies from an older workspace, if you have any. For example this set of requirements works in my case, but the updated ones not anymore. I don't know which version exactly causes the problem.
There is a workaround, you can use dependencies from an older workspace, if you have any. For example this set of requirements works in my case, but the updated ones not any more. I don't know which version exactly causes the problem.
Actually just pip install notebook==6.0.3
works for me
Edit: complete requirements.txt
that works, few packages downgraded.
requirements.txt
@Krendelev Unfortunately this workaround isn't working for me.
Just want to echo I have the same issue starting this morning and it seems like microsoft/vscode-jupyter#685 may be referring to the same problem.
Strangely, this bug is also present when using devcontainers. It doesn't seem to be linked to the version of Python.
Looking into it now. The logs that I've seen all have signature mismatch issues.
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
If this works (or doesn't) for you please post back as I have only my data point to work with.
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Confirming that this resolves the issue. Thank you for looking into it.
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history In an activated environment that is not working try the following to drop it back to the older version: python -m pip install 'traitlets==4.3.3' --force-reinstall Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Confirmed on my end (Python3.8.5 64-bit; Windows).
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
This really helped!
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Thank you very much
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
I just started today with VScode+jupyter (was already in with anaconda). This issue really tired me up and took my 4-5 hours to get to this post. FIrstly there was some compatibility issue with conda env kernel and then this stuff came up. but this solution saved my day. Thanks a lot
Thank you very much! It is working now. Quotation marks are not necessary:
python3 -m pip install traitlets==4.3.3 --force-reinstall
or
pip3 install traitlets==4.3.3 --force-reinstall
On Tue, Sep 1, 2020 at 11:56 AM liteform notifications@github.com wrote:
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version: python -m pip install 'traitlets==4.3.3' --force-reinstall Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Confirming that this resolves the issue. Thank you for looking into it.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/microsoft/vscode-python/issues/13701#issuecomment-684998235, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACM2HQQAJZTBZHEHLI243SLSDURSLANCNFSM4QQ4BE3Q .
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
perfect for me! thanks!
I feel like I'm missing something? When I run python -m pip install 'traitlets==4.3.3' --force-reinstall
and then open up VS Code and start up a new notebook, it tells me Data Science library ipykernel is not installed. Install?
And if I select "Yes" it will update and then send me back to the Unable to start session for kernel Python 3.8.5 32-bit.
Basically putting me in a loop.
python -m pip install 'traitlets==4.3.3' --force-reinstall
confirmed to work for me. Thanks a lot.
Python 3.8.5 32-bit on Windows 10 64-bit
python3 -m pip install traitlets==4.3.3 --force-reinstall
worked for me as well. Python 3.8.2 64-bit on Windows 10 64-bit
I feel like I'm missing something? When I run
python -m pip install 'traitlets==4.3.3' --force-reinstall
and then open up VS Code and start up a new notebook, it tells meData Science library ipykernel is not installed. Install?
And if I select "Yes" it will update and then send me back to theUnable to start session for kernel Python 3.8.5 32-bit.
Basically putting me in a loop.
Go to vscode (change the python interpreter to what you want), then run
python -m pip install ipykernel
and then do the degradation by
python -m pip install 'traitlets==4.3.3' --force-reinstall
because when you are degrading it first then the installation of ipykernel updates it again nullfying your degradation
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history In an activated environment that is not working try the following to drop it back to the older version: python -m pip install 'traitlets==4.3.3' --force-reinstall Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Confirmed on my end (Python3.8.5 64-bit; Windows).
"python -m pip install traitlets==4.3.3 --force-reinstall --user" It works perfectly now! Thanks very much!!!!!
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
also works for me, thank you!
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
It worked, thanks!
Thank you very much! It is working now. Quotation marks are not necessary: python3 -m pip install traitlets==4.3.3 --force-reinstall or pip3 install traitlets==4.3.3 --force-reinstall … On Tue, Sep 1, 2020 at 11:56 AM liteform @.***> wrote: Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history In an activated environment that is not working try the following to drop it back to the older version: python -m pip install 'traitlets==4.3.3' --force-reinstall Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start). Confirming that this resolves the issue. Thank you for looking into it. — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#13701 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACM2HQQAJZTBZHEHLI243SLSDURSLANCNFSM4QQ4BE3Q .
Really worked!
Go to vscode (change the python interpreter to what you want), then run
python -m pip install ipykernel
and then do the degradation bypython -m pip install 'traitlets==4.3.3' --force-reinstall
because when you are degrading it first then the installation of ipykernel updates it again nullfying your degradation
Well, like I said, I seem to be stuck in a loop. if I install ipykernel, then I can't start a session. So then I need to do the degradation. But the problem here is that if I degrade it, vscode keeps telling me that I don't have an ipykernel installed. Therefore, it still doesn't work.
Here's the other thing, after running python -m pip install 'traitlets==4.3.3' --force-reinstall
, if I were to install ipykernel with pip, nothing happens as all my requirement are satisfied. Its just that if I try to select an interpreter for notebooks, again, vscode will force me to install Data Science library ipykernel and it will add Installing collected packages: ipython-genutils, traitlets, six, decorator
. This seems to be the only difference between installing through VS Code and using python -m pip install ipykernel
.
I should also add that this is my first time installing and running notebooks on vscode, so I don't have any older versions to revert back to maybe? I'm honestly not sure what's going on.
@dwang040 Sounds like you are dealing with a different issue here. Could you please file a new issue on this? Also turning Python->Logging->Level setting to 'debug' and then including the contents of the Output:Python window could help us to diagnose this.
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Also works very well for me, thanks
If someone here is using pipenv to manage your packages, use the command below to install this package
pipenv install jupyter
pipenv install traitlets==4.3.3
With both commands you can create the complete environment to work with jupyter notebook on vscode.
OMG!!!! You guys have just saved my life!!!! I've been trying to solve this problem for HOURS!!!!
I'm using Ubuntu 20.04. I've installed jupyter using "sudo pip3 install jupyter" in the terminal and jupyter notebook was working completely fine in the browser. However, when I tried to create a notebook in VSCode I got the message "Connecting to IPython kernel: Connecting to kernel", and, after some minutes, the message "Unable to start session for kernel python 3.8".
As suggested here, first I exited VSCode. Then I checked the version of "traitlets" installed, using the following command in ubuntu terminal:
$ pip3 freeze | grep traitlets
And it was installed some 5 version...
Then, I used the following command in ubuntu terminal:
$ sudo pip3 install "traitlets==4.3.3" --force-reinstall
Reopened VSCode and ran a notebook! Worked PERFECTLY!!!!
Thank you very much you all, specially @IanMatthewHuff !!!!
Worked for me too - python 3.8.5 on 64-bit windows10
If this works (or doesn't) for you please post back as I have only my data point to work with.
Thanks a lot! this solved my problem:
Unable to start session for kernel Python 3.7.7 64-bit ('venv': venv). Select another kernel to launch with.
Thank you very much! It is working now. Quotation marks are not necessary: python3 -m pip install traitlets==4.3.3 --force-reinstall or pip3 install traitlets==4.3.3 --force-reinstall
This worked - 3.8.3 64bit MacOS, thank you! :)
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Works for me 👍
This worked for me, following the instructions for Pipenv mentioned by @pedrom505
Thank you!!
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
Worked for me, thank you! But is there anyone working on a more permanent fix that works with the latest version of traitlets
and other things?
Hi, I tried the solutions above, but they did not work for me. I also tried the solutions here, but they did not work either. I'm very new to visual studio so all help is appreciated. Thank you!
Worked easily and well for me. Many thanks @IanMatthewHuff and team!
python -m pip install 'traitlets==4.3.3' --force-reinstall
Yes it worked for me as well :-)
This should be fixed with latest traitlets 5.0.4, out earlier today. I haven't been able to confirm directly, since I don't know how to trigger the relevant code path myself, but manually executing a similar command-line is fixed with 5.0.4.
But is there anyone working on a more permanent fix that works with the latest version of traitlets and other things?
This extension shouldn't need any updating, but the relevant change is that this b'
prefix for configuring Bytes on the command-line is no longer required and support is deprecated (with no plans for removal). The bug was in traitlets 5,<5.0.4 not properly implementing the deprecated support for this prefix. It can be dropped if/when traitlets >=5.0 is required, but until then no changes are necessary. I wouldn't rush, though, as pinning down is likely to be a common practice as bugs are worked out during a transition period.
This should be fixed with latest traitlets 5.0.4, out earlier today. I haven't been able to confirm directly, since I don't know how to trigger the relevant code path myself, but manually executing a similar command-line is fixed with 5.0.4.
But is there anyone working on a more permanent fix that works with the latest version of traitlets and other things?
This extension shouldn't need any updating, but the relevant change is that this
b'
prefix for configuring Bytes on the command-line is no longer required and support is deprecated (with no plans for removal). The bug was in traitlets 5,<5.0.4 not properly implementing the deprecated support for this prefix. It can be dropped if/when traitlets >=5.0 is required, but until then no changes are necessary. I wouldn't rush, though, as pinning down is likely to be a common practice as bugs are worked out during a transition period.
-This worked for me
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
This worked for me - Thank you! Python 3.8.5 MacOS 10.15.6
I had traitlets 4.3.3 installed already, so I tried upgrading. In the respective conda env, I upgraded traitlets to 5.0.4 and still get the kernelspec error unless I open vscode via the anaconda3 command prompt.
Interestingly this issue is not present when I run an interpreter on the host from a remote client via the SSH remote extension
python 3.7.7 vs code 1.49 win10 x64
Worked for me. Thanks! Python 3.8.5 vscode 1.49 win10 x64
Hope to solve this problem, I spent a long time to solve this problem, but those who did not see this page are not so lucky, maybe they will give up using VSCODE's jupyter notebook function
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
WORKED! Thank You :))
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
This is great! Fixed the issue. Cheers!
Hey folks. In my local testing I believe that it was this update here to 5.0.0, which is picked up as part of our ipykernel install: https://pypi.org/project/traitlets/#history
In an activated environment that is not working try the following to drop it back to the older version:
python -m pip install 'traitlets==4.3.3' --force-reinstall
Make sure to have VS Code closed (as we sometimes are starting a kernel in the background, this will make sure that you pick up the install fresh the next time that you start).
traitlets==4.3.3
worked for me also thank you!
This should be fixed with latest traitlets 5.0.4, out earlier today.
I can confirm that upgrade to 5.0.4 fixed it for me:
pip3 install -U traitlets
Bug: Notebook Editor, Interactive Window, Editor cells
Unable to start session for kernel Python 3.8.5 32-bit ('venv': venv). Select another kernel to launch with.
Steps to cause the bug to occur
There is really nothing special here
python -m venv venv
Actual behavior
Unable to start session for kernel Python 3.8.5 32-bit ('venv': venv). Select another kernel to launch with.
Expected behavior
Notebook runs!
Your Jupyter and/or Python environment
Please provide as much info as you readily know
Python Output
The notebook can't run so there is nothing to copy here. However, here is the installed package in the environment if it helps at all:
Package Version
argon2-cffi 20.1.0 attrs 20.1.0 backcall 0.2.0
bleach 3.1.5
cffi 1.14.2 colorama 0.4.3
decorator 4.4.2
defusedxml 0.6.0
entrypoints 0.3
flake8 3.8.3
ipykernel 5.3.4
ipython 7.18.1 ipython-genutils 0.2.0
ipywidgets 7.5.1
jedi 0.17.2 Jinja2 2.11.2 jsonschema 3.2.0 jupyter 1.0.0 jupyter-client 6.1.7 jupyter-console 6.2.0 jupyter-core 4.6.3 MarkupSafe 1.1.1 mccabe 0.6.1 mistune 0.8.4 nbconvert 5.6.1 nbformat 5.0.7 notebook 6.1.3 packaging 20.4 pandocfilters 1.4.2 parso 0.7.1 pickleshare 0.7.5 pip 20.1.1 prometheus-client 0.8.0 prompt-toolkit 3.0.7 pycodestyle 2.6.0 pycparser 2.20 pyflakes 2.2.0 Pygments 2.6.1 pyparsing 2.4.7 pyrsistent 0.16.0 python-dateutil 2.8.1 pywin32 228 pywinpty 0.5.7 pyzmq 19.0.2 qtconsole 4.7.6 QtPy 1.9.0 Send2Trash 1.5.0 setuptools 47.1.0 six 1.15.0 terminado 0.8.3 testpath 0.4.4 tornado 6.0.4 traitlets 5.0.0 wcwidth 0.2.5 webencodings 0.5.1 widgetsnbextension 3.5.1
Microsoft Data Science for VS Code Engineering Team: @rchiodo, @IanMatthewHuff, @DavidKutu, @DonJayamanne, @greazer, @joyceerhl