0

It seems I am missing something or have the completely wrong expectations so let me start by listing my expectations:

If:

  1. I get a yml dump of an Anaconda environment from a colleague
  2. I install Anaconda on my machine and run: conda env create -f enviornmentDump.yml

Expectation: I now have a working environment with all things I need

Actual result: I got a long list of not found packages

Is the thing actually not installing things but just checking locally if what I want already is installed? If so, what is the use case for this (because it seems extremely limited) and what should I use in my case?


EDIT: What my errors look like

$ conda env create -f dump.yml
Collecting package metadata (repodata.json): done
Solving environment: failed

ResolvePackageNotFound:
  - stevedore==3.3.0=py38haa244fe_1
  - pyyaml==5.4.1=py38h294d835_0
  - pip==21.0.1=py38haa95532_0
             [...]
  - numpy==1.19.2=py38hadc3359_0
jonalv
  • 5,706
  • 9
  • 45
  • 64
  • Might be stupid questions, but 1) Are you sure you are using the created environment? 2) How did your colleague create dump? 3) Could you check if some of the packages missing are listed in the .yml or are they "unlisted dependencies"? – Tzane Sep 01 '21 at 08:48
  • 1) I am sure I am not using the created environment because the failing was during the creation of it 2) Not sure, can it actually be done in more than one way? 3) They are listed as dependencies (rather, at least one is) – jonalv Sep 01 '21 at 09:03
  • When you say "long list of not found packages" do you mean those are not found by conda in any of the repositories when you are creating the environment? – Tzane Sep 01 '21 at 09:28
  • @Tzane: I actually don't know if that is what I mean, it seems to me it is just checking what is available locally and then fails. But maybe that is not the case? – jonalv Sep 01 '21 at 09:32

1 Answers1

3

So conda is check the online package repositories whether or not the listed packages are available with the specified version and build. In your case it fails because some of the specifications cannot be satisfied.

You could try removing the build number, which is the string after the last "=", for numpy it is "py38hadc3359_0". Or if you can ask your colleague to create a new dump without them with --no-build flag such as:

conda env export --no-builds > dump.yml

I don't usually include the build when specifying the env, version number should be enough. There might be some differences between different OS for the exact build.

Tzane
  • 2,752
  • 1
  • 10
  • 21