What did I do/ how can I recover my old conda environment in Python?

Viewed 47

I have a go-to conda environment called 'pyvizenv'.

I would use it in python and jupyter labs but it couldn't load plotly/pyviz, so I decided to create a new environment called 'testenv'.
I successfully created the new environment but now it appears it messed something up in my 'pyvizenv' environment.

I get errors in git bash when I try to use it such as:

EnvironmentLocationNotFound: Not a conda environment: C:\Users\LouD\anaconda3\envs\pyvizenv
ImportError: DLL load failed while importing error: The specified module could not be found

Is there any way I can recover 'pyvizenv' or figure out what went wrong?

Here is the code I used in git bash to create my new environment 'testenv':

conda create -n testenv python=3.7 anaconda -y
conda activate testenv
pip install python-dotenv
conda install -c anaconda nb_conda -y
conda install -c conda-forge nodejs -y
conda install update nodejs
conda install -c pyviz holoviz -y
conda install -c plotly plotly -y
set NODE_OPTIONS=--max-old-space-size=4096
jupyter labextension install @jupyter-widgets/jupyterlab-manager --no-build
jupyter labextension install jupyterlab-plotly@4.6.0 --no-build
jupyter labextension install plotlywidget@4.6.0 --no-build
jupyter labextension install @pyviz/jupyterlab_pyviz --no-build
jupyter lab build
set NODE_OPTIONS=

Also I am able to see both environments under this location in my folders. (Not sure if this helps)
C:\Users\LouD\anaconda3\envs

1 Answers

set NODE_OPTIONS=... suggests a CMD session.
That set command would not work in a git-bash session.

So try first and make it work as a regular CMD script, or in a regular CMD shell, before testing your environment in git bash.

Related