winnibear
winnibear

Reputation: 41

Met `Solving environment: failed` error when doing `conda env`

I have python 3.7 and latest anaconda.(MacOS 10.14.5)

I am having Solving environment: failed issue with this error code.

ResolvePackageNotFound: 
  - twisted==17.5.0=py36_0

could anyone tell me how to solve this problem?

Thank you in advance.

conda env create -f cvcourse_macos.yml 


(base) Simons-MacBook-Pro:~ paladalgom$ cd Downloads
    (base) Simons-MacBook-Pro:Downloads paladalgom$ conda env create -f cvcourse_macos.yml 
    Collecting package metadata (repodata.json): done
    Solving environment: failed

    ResolvePackageNotFound: 
      - twisted==17.5.0=py36_0

(base) Simons-MacBook-Pro:Downloads paladalgom$ - twisted==17.5.0=py36_0

Upvotes: 4

Views: 2019

Answers (2)

regina_fallangi
regina_fallangi

Reputation: 2198

Open the file cvcourse_macos.yml with your favourite editor.

If you are newer to programming, try Sublime or Atom.

The .yml file may have the following structure:

name: python-cvcourse
channels:
  ...
dependencies:
  ...
  - pip=10.0.1=py36_0
  ...

Under the that pip=10.0.1=py36_0 line add:

  - pip=10.0.1=py36_0:
    - twisted==17.5.0=py36_0

Notice the : after - pip=10.0.1=py36_0 and the 4 spaces or indentation for the next line.

The dependency twisted==17.5.0=py36_0 will be somewhere in the dependencies list, delete that other occurrence and keep the one you added.

After that, save your file and run conda env create -f cvcourse_macos.yml again.

Alternative:

That concrete python-cvcourse is part of a Computer Vision course in Udemy. I've done it and can say: feel free to delete the "twisted=17.5,0=py36_0" line. You will not need it. The tbb.. one as well, as, dependiing on conda version, runs against an endless loop.

Upvotes: 1

Pasan Chamikara
Pasan Chamikara

Reputation: 755

In env.yml of conda, put twisted==17.5.0=py36_0 under pip section.

Upvotes: 0

Related Questions