Fixing Jupyter Desktop Set Python Environment Error Message
by Mike LevinWednesday, June 22, 2022
I’m currently JupterLab-Desktop 3.3.4-2 and got an error message I hadn’t seen since the last version 3.3.4-1 I had to skip (because of this error). But I got it spontaneously on the latest version I’ve been using for months and I can’t let JupyterLab Desktop get taken away from me, so I decided to fix it.
Would have liked to have gotten back to LXD.
In my attempt to fix the Jupyter Desktop Set Python Environment problem, I:
- Installed the official (and best) Python 3.10.5 from Python.org
- Not from the Microsoft store (much easier) (type python from com or powershell)
- I checked if venv came with the python.exe from python.org
- It did
- I could use it with carefully controlled paths to .\python.exe
- And the use of the -m switch (arg or parameter)
- I created a venv named pyw3105 in my C:\Users[username]\pyw3105
- Without source activate (the way you activate venv’s)
- After I had that virtualenv, I was able to install the py 3.10 kernel
- per the instructions at
- .\python.exe -m pip install ipykernel
- I cd’d C:\Users[username] …because my venv resided here
- .\python.exe -m ipykernel install –user –name pyw3105
And that “registered” the new Python 3.10.5 kernel with JupyterDesktop and it’s now my default (yay!)
To get JupyterLab working again, I believe it was a result of deleting the JupyterLab config file:
Found in a Windows path like:
I am sorry I had to break this into two videos and that I went the long way in fixing it. However, I’m very happy I’m on Python 3.10.5 in JupyterLab now.
Perhaps it was providence that it spontaneously stopped working (giving that Jupyter Desktop Set Python Environment error).