mamba: conda 23.9.0 breaks mamba 1.5.1
Troubleshooting docs
- My problem is not solved in the Troubleshooting docs
How did you install Mamba?
Mambaforge
Search tried in issue tracker
ensure
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
using mamba 1.5.1 and upgrading to conda 23.9.0 breaks mamba:
$ mamba info
Traceback (most recent call last):
File "C:\Users\cpi-eng\miniconda3\Scripts\mamba-script.py", line 6, in <module>
from mamba.mamba import main
File "C:\Users\cpi-eng\miniconda3\Lib\site-packages\mamba\mamba.py", line 16, in <module>
from conda.cli.common import (
ImportError: cannot import name 'ensure_name_or_prefix' from 'conda.cli.common' (C:\Users\cpi-eng\miniconda3\Lib\site-packages\conda\cli\common.py)
mamba info / micromamba info
n/a
Logs
No response
environment.yml
No response
~/.condarc
No response
About this issue
- Original URL
- State: closed
- Created 9 months ago
- Reactions: 22
- Comments: 24 (9 by maintainers)
Commits related to this issue
- pin to conda <23.9.0a0 works around https://github.com/mamba-org/mamba/issues/2882 — committed to duncanmmacleod/mamba-feedstock by duncanmmacleod 9 months ago
- Mamba and conda incompatibility resolved See [mamba/2992](https://github.com/mamba-org/mamba/issues/2882). This image is built on a new jupyter/minimal-image to avoid that problem. Aside from that, i... — committed to callysto/2i2c-image by ianabc 8 months ago
The repodata has been patched, mamba 1.5.1 now pins conda < 23.9.0, so a fresh install should work out of the box.
In the meantime mamba has been patched to support latest conda, we will release 1.5.2 with this fix in a few days.
Downgrading
condato 23.7.4 fixes the issue.Can confirm that the updated versions are available now. Doing a
mamba update --allit downloaded and installed Conda 23.9.0 and Mamba 1.5.2. Everything seems to be working fine so far, at least until the next minor Conda update 😛It does, see https://github.com/conda-forge/mamba-feedstock/blob/f707a5abe0e1728326263035042ba49c505cb486/recipe/meta.yaml#L126. Unfortunately, sometimes conda releases minor versions that break backward compatibility.
See https://github.com/mamba-org/mamba/pull/2878
the solution at this point is to downgrade conda (mentioned above)
When is the fix finally going to be released?
updates to conda breaking mamba has happened to me more than once. why don’t mamba’s dependencies constrain the conda version???
@JohanMabille Sorry, I was digging a bit deeper and I seem to have a different issue. My
mamba(andcondatoo) simply saysAll requested packages already installedto anyupdatecommands. Looking withsearchis even missing some versions that I know exist. It started to appear after update to1.5.1, but now even older versions (1.1.0on one HPC) have this same problem, while they worked in the past (but on another HPC I have0.15.3which works fine, so it’s not just server-side issue either). I’ll open a new issue when I have some more time.run
mamba update --allin my base env (which was in 1.5.1) and mamba correctly updated to 1.5.2 with conda 23.9.0. All mamba commands working as expected (I updated my other envs with no problem, and they execute well). Thanks for the fix !As soon as the CI passes on the branch 1.x. I’m backporting the required bugfixes, and I will release as soon as I can (hopefully today).
Soo, what is the solution? Downgrade to previous version or? Trying to follow the linked discussion thread but not quite sure what to make of it, there’s some temporary fixes somewhere, then that the issue is fixed somewhere else.