Jupyter keeps running the 'base' conda environment
See original GitHub issueIssue Type: Bug
I have a specific conda environment ‘my_env’.
I can select it to be used as a kernel, in the top right of the notebook, with “Jupyter Server: local”.
But, when I try to execute code in the notebook, such as
os.getenv('CONDA_DEFAULT_ENV')
it still says it’s using the ‘base’ environment, and can’t find the installed packages.
Bottom left of VS Code says the interpreter is Python…(‘my_env’). When I open a new terminal it activates ‘my_env’ but the kernel keeps running ‘base’.
This used to work well, but now it’s broken.
Extension version: 2021.2.576440691 VS Code version: Code 1.53.2 (622cb03f7e070a9670c94bae1a45d78d7181fbd4, 2021-02-11T11:48:44.518Z) OS version: Linux x64 5.8.0-43-generic snap
System Info
Item | Value |
---|---|
CPUs | Intel® Core™ i7-8565U CPU @ 1.80GHz (8 x 2932) |
GPU Status | 2d_canvas: unavailable_software gpu_compositing: disabled_software multiple_raster_threads: enabled_on oop_rasterization: disabled_off opengl: disabled_off protected_video_decode: disabled_off rasterization: disabled_software skia_renderer: enabled_on video_decode: disabled_software vulkan: disabled_off webgl: unavailable_software webgl2: unavailable_software |
Load (avg) | 3, 3, 3 |
Memory (System) | 15.49GB (1.72GB free) |
Process Argv | –force-user-env --no-sandbox --unity-launch --no-sandbox --crash-reporter-id e0b4888e-7039-4296-a9e5-65e00d3fce86 |
Screen Reader | no |
VM | 0% |
DESKTOP_SESSION | ubuntu |
XDG_CURRENT_DESKTOP | Unity |
XDG_SESSION_DESKTOP | ubuntu |
XDG_SESSION_TYPE | x11 |
A/B Experiments
vsliv368:30146709
vsreu685:30147344
python383:30185418
vspyt653:30253241
vspor879:30202332
vspor708:30202333
vspor363:30204092
vstry244:30256636
pythonvsdeb440:30248342
pythonvsded773:30248341
vstes627:30244334
pythonvspyt875:30259475
dockersubsetcf:30263000
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Get Your Conda Environment to Show in Jupyter Notebooks
1. First, install nb_conda_kernels in your base environment. Once this is installed any notebook running from the base environment will ...
Read more >Jupyter notebook only works in base environment
I have reinstalled Anaconda and Jupyter, restarted PC and used ip 127.0.0.1 instead of localhost, but nothing helps. What should I do? I...
Read more >Conda always pointing to base environment regardless the ...
when i run the command “conda env list” on jupyter notebook it is always pointing to the base environment which is wrong. !conda...
Read more >Jupyter will not change environments when using conda #4011
Changing conda environment at bottom left corner or python interpreter at top right corner does not changing the contents of sys.exeutable.
Read more >What to do when things go wrong - The Jupyter Notebook
If you're using a menu shortcut or Anaconda launcher to start it, try opening a terminal or command prompt and running the command...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Having the same problem, python interactive only selecting the base kernel. For me downgrading the jupyter extension instead of the python extension fixed the problem, the problem starts from jupyter extension 2021.2.0 for me.
@DonJayamanne Thanks for your efforts. I just tested the latest Jupyter extension in VS Code Insiders, and the problem is resolved. Thanks again.