Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does `conda update --all` not update all?

Similar to this question, but there's no answer there.

I installed anaconda, and then conda install -c conda-forge geopandas. When I ran import geopandas, I got

>>> import geopandas as gpd
anaconda3/envs/gis/lib/python3.7/importlib/_bootstrap.py:219: 
RuntimeWarning: numpy.dtype size changed, may indicate binary 
incompatibility. Expected 96, got 88 
return f(*args, **kwds)

So, I tried updating all packages of my Anaconda env like conda update --all, but that didn't solve the warnings. What did solve it was updating the specific package: conda update numpy.

So, my question is: what does conda update --all do, that it doesn't update all packages?

like image 272
Dervin Thunk Avatar asked Jan 02 '23 12:01

Dervin Thunk


1 Answers

The conda update documentation states that:

"This command accepts a list of package names and updates them to the latest versions that are compatible with all other packages in the environment." -- emphasis mine

This means that conda update will not update some packages if updating may put the stability of other packages at risk. As such, conda update -all is likely prioritizing stability over more recent builds. Whereas, conda update numpy is prioritizing the numpy update with minimal/no regard to overall stability.

As a side note, I have previously broken package stability for other installs doing exactly that -- updating a single package to its most recent version.

like image 163
compBio Avatar answered Jan 04 '23 00:01

compBio