Environment gets activated after debugger starts (hence debugging with conda envs fail)
See original GitHub issueEnvironment data
- VS Code version: Just updated
- Extension version (available under the Extensions sidebar): Just updated
- OS and version: Windows 10
- Python version (& distribution if applicable, e.g. Anaconda): Python 3.7, Conda3
- Type of virtual environment used (N/A | venv | virtualenv | conda | …): conda
Issue
Use Debug Python: Current File…
> cd ...
[...]
from matplotlib import afm, cbook, ft2font, rcParams, get_cachedir
ImportError: DLL load failed: The specified module could not be found.
>D:/Anaconda3/Scripts/activate
>conda activate base
Terminal stays open so I can click again the play icon and it works because conda activate base
activated Python environment just AFTER the debugger FAILED to start.
Thank you.
Issue Analytics
- State:
- Created 4 years ago
- Comments:21
Top Results From Across the Web
How do I activate my conda environment for VS Code python ...
1. pythonPath property of the selected debug configuration in launch.json. My launch.json file: · 2. python.pythonPath setting in the workspace ...
Read more >terminal not activating the conda environment : PY-23417
Trying to 'run' or 'debug' a script with my python interpreter set to my conda env does not activate the conda env, so...
Read more >Efficient Way to Activate Conda in VSCode - Medium
With these three steps you can initiate your debug through “integrated terminal” which has the full control power to activate conda environment, while...
Read more >Settings Reference for Python - Visual Studio Code
For general information about working with settings in VS Code, refer to User ... level of information provided, are off , error ,...
Read more >Getting Started with PythonWin
Installing PythonWin -- Oh, and Python Environments, Conda , and Pip Python ... to debug them, and even to execute Python statements or...
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
That is the plan.
@DonJayamanne Can you clarify your proposed solution of
conda run
? Are you proposing a modified launch configuration? Could you provide an example?