[Python] conda env remove -n ENV_NAME consistently leaving behind folder

Discussão em 'Python' iniciado por Stack, Agosto 27, 2025.

  1. Stack

    Stack Membro Participativo

    Both conda env remove -n ENV_NAME and conda remove -n ENV_NAME --all consistently leave a folder behind when executing the commands.

    This becomes an issue if I'm trying to recreate the environment--I'm using batch scripts to create the environment so as I adjust the script, I repeatedly create/remove the env.

    When the folder is left behind, this becomes an issue and then prevents me from creating a fresh env with the same name.

    Right now I navigate into C:\ProgramData\anaconda3\envs to manually delete the folder, but I cannot figure out what is preventing the folder from being deleted by the conda commands

    I have deactivated the environment, ensured all my terminals/shell windows are closed, and made sure that VSCode/any other IDE was closed. I Understand that all processes that might be referencing the env can prevent proper deletion. But as far as I can tell it is not being referenced by anything but still leaves behind a folder.

    Continue reading...

Compartilhe esta Página