Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix "UnsatisfiableError: The following specifications were found to be incompatible with each other: - pip -> python=3.6"

So, i trying to install with the command ecmwf api client conda install -c conda-forge ecmwf-api-client then the warning in the title shows up. I don't know how to proceede

(base) C:\Users\caina>conda install -c conda-forge ecmwf-api-client Collecting package metadata (current_repodata.json): done Solving environment: failed Collecting package metadata (repodata.json): done Solving environment: failed

UnsatisfiableError: The following specifications were found to be incompatible with each other:

  • pip -> python=3.6
like image 567
Cainã Oliveira Avatar asked Jul 04 '19 23:07

Cainã Oliveira


People also ask

How do I change the Conda environment in python?

Open up your terminal. Search for available versions - can search for what you want, but we'll look for “python” > conda search python which returns something like this: Fetching package metadata: . To change your python version, you can now just type: conda install python=3.5.

How do I downgrade python to Anaconda?

How do I downgrade a python package? Upgrade and Downgrade a Python Package. Upgrade and Downgrade are similar, both of which follow two steps: (1) uninstall the previous package; (2) install the current package. Update a package by pip: pip install -U [package name].


2 Answers

Install into a new environment instead of the conda base environment. Recent Anaconda and Miniconda installers have Python 3.7 in the base environment, but you're trying to install something that requires Python 3.6.

like image 55
Roland Weber Avatar answered Oct 29 '22 23:10

Roland Weber


As others have said, it's recommended to create a new, clean environment and conda install into that.

This can be done with the following:

# Create new environment
conda create --name <name> python=3.6
# Activate new environment
conda activate <name>
# Install packages into new environment
conda install -c conda-forge ecmwf-api-client

It's a good idea to keep various environments for different projects. You can then use conda deactivate/conda activate <name> and install any packages into the correct environment. This also allows you to easily swap between different versions of python, or individual software packages.

like image 31
QuantumChris Avatar answered Oct 30 '22 00:10

QuantumChris