Image cannot be rebuilt from a previously working environment.yml file

Dear all,

two months ago I set up a with an environment.yml file. I am not sure whether I am using the correct terms, but I accessed mybinder, added the path to my GitHub repository that I wanted to make available, clicked launch and it worked.

Today, I added a single jupyter notebook to that GitHub repository, and tried to build it again in mybinder. However, this error prevents the image to be built.


Just to make it clear, I didn’t change the environment.yml file. These two packages were already there when it worked.

How to solve? What to do?

I am sorry if my question doesn’t reach the desired standards. Some terms are confusing to me.

Hi @leomiquelutti -

These two packages were already there when it worked.

Yes, unfortunately you did everything right (you have a fully pinned environment file) but sometimes upstream changes in conda make that environments that used to work won’t work anymore.

How to solve? What to do?

You can try to unpin the packages first (change eg basemap=1.0.7 to basemap) and try to use the conda-forge channel to install your package (see here for an example). Once it’s working, you might want to try pinning your packages again.


+1 to giving conda-forge a shot for the channel, I’ve found it to be more dynamic in keeping up with dependency changes etc.

1 Like

It worked! Thanks a lot!

I tried to unpin only numba and basemap, but only worked when everything was unpinned.

Now a question, @fmaussion: why would I want to pin packages again? Why can that be an issue?

Mostly for more predictable results ( As long as the installation works, you will make sure that your code will always work the same (you have a few dependencies which are close to end-of-life: python 2.7, basemap). But as you’ve noted, there is no guarantee that it will always work anyways, so it’s your choice if you want to pin them or not.

1 Like