Skip to content

Mamba 2.0 does not allow creating an environment prefix in place of an existing directory #3845

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
3 tasks done
bernt-matthias opened this issue Feb 27, 2025 · 0 comments · May be fixed by #3853
Open
3 tasks done
Labels
type::bug Something isn't working

Comments

@bernt-matthias
Copy link

Troubleshooting docs

  • My problem is not solved in the Troubleshooting docs

Anaconda default channels

  • I do NOT use the Anaconda default channels (pkgs/* etc.)

How did you install Mamba?

Mambaforge or latest Miniforge

Search tried in issue tracker

#2402

Latest version of Mamba

  • My problem is not solved with the latest version

Tried in Conda?

I do not have this problem with Conda, just with Mamba

Describe your issue

If there an existing folder X I get for mamba >= 2.0:

mamba create -p /usr/local/
error    libmamba Non-conda folder exists at prefix                                                                                                                   
critical libmamba Aborting.          

and for Mamba < 2.0

WARNING: A directory already exists at the target location '/usr/local'
but it is not a conda environment.

conda behaves like mamba < 2.0

I'm using the latest miniforge container. Mamba >=2 is installed with conda in the container.

see also #2402

mamba info / micromamba info

active environment : base
    active env location : /opt/conda
            shell level : 1
       user config file : /root/.condarc
 populated config files : /opt/conda/.condarc
          conda version : 25.1.1
    conda-build version : not installed
         python version : 3.12.8.final.0
                 solver : libmamba (default)
       virtual packages : __archspec=1=skylake
                          __conda=25.1.1=0
                          __glibc=2.31=0
                          __linux=6.11.0=0
                          __unix=0=0
       base environment : /opt/conda  (writable)
      conda av data dir : /opt/conda/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
          package cache : /opt/conda/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/conda/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/25.1.1 requests/2.32.3 CPython/3.12.8 Linux/6.11.0-17-generic ubuntu/20.04.6 glibc/2.31 solver/libmamba conda-libmamba-solver/25.1.1 libmambapy/2.0.5
                UID:GID : 0:0
             netrc file : None
           offline mode : False

Logs

environment.yml

~/.condarc

@jjerphan jjerphan added the type::bug Something isn't working label Mar 5, 2025
@jjerphan jjerphan changed the title Mamba 2.0 can't create an environment that is an empty folder Mamba 2.0 does not allow creating an environment prefix on an existing directory Mar 6, 2025
@jjerphan jjerphan changed the title Mamba 2.0 does not allow creating an environment prefix on an existing directory Mamba 2.0 does not allow creating an environment prefix in place of an existing directory Mar 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type::bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants