r-darwish / topgrade

Upgrade everything
GNU General Public License v3.0
3.36k stars 160 forks source link

8.2.0 broke conda's `auto_activate_base: false` #840

Closed bdaase closed 2 years ago

bdaase commented 2 years ago

I have the following line in my .condarc to not have an active base by default

auto_activate_base: false

What did you expect to happen?

When running topgrade I expect that it can either deal with it or does nothing.

What actually happened?

Instead topgrade shows

―― 14:33:32 - Conda ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――

NoBaseEnvironmentError: This conda installation has no default base environment. Use
'conda create' to create new environments and 'conda activate' to
activate environments.

Retry? (y)es/(N)o/(s)hell

Additional details:

r-darwish commented 2 years ago

Is there any Conda command that Topgrade can run to check this? I rather not start parsing Conda's config by myself.

bdaase commented 2 years ago

I have no idea tbh.

bdaase commented 2 years ago

Checking for echo $CONDA_PREFIX should work. When the result is empty, no environment is active.

r-darwish commented 2 years ago

What's the outpost of conda config --show auto_activate_base?

bdaase commented 2 years ago
aucto_activate_base: False