Reputation: 2250
Having trouble installing a third party library and I have not seen this error before using Windows 10 with Anaconda installed:
C:\Users\XYZ>conda env create -f python3.6-environment-windows.yml
Collecting package metadata: done
Solving environment: done
Downloading and Extracting Packages
certifi-2018.1.18 | 144 KB | ############################################################################ | 100%
mkl-2018.0.1 | 155.2 MB | ############################################################################ | 100%
pytz-2018.9 | 229 KB | ############################################################################ | 100%
icc_rt-2019.0.0 | 9.4 MB | ############################################################################ | 100%
icu-58.2 | 21.8 MB | ############################################################################ | 100%
pip-9.0.1 | 1.7 MB | ############################################################################ | 100%
xz-5.2.3 | 348 KB | ############################################################################ | 100%
sip-4.18.1 | 269 KB | ############################################################################ | 100%
libpng-1.6.36 | 1.3 MB | ############################################################################ | 100%
vc-14 | 985 B | ############################################################################ | 100%
numpy-1.14.0 | 3.7 MB | ############################################################################ | 100%
python-3.6.4 | 17.6 MB | ############################################################################ | 100%
jpeg-9c | 314 KB | ############################################################################ | 100%
wheel-0.30.0 | 85 KB | ############################################################################ | 100%
wincertstore-0.2 | 13 KB | ############################################################################ | 100%
freetype-2.9.1 | 475 KB | ############################################################################ | 100%
scipy-1.0.0 | 13.0 MB | ############################################################################ | 100%
pyparsing-2.3.1 | 54 KB | ############################################################################ | 100%
kiwisolver-1.0.1 | 60 KB | ############################################################################ | 100%
qt-5.6.2 | 55.6 MB | ############################################################################ | 100%
python-dateutil-2.7. | 218 KB | ############################################################################ | 100%
vs2015_runtime-14.0. | 1.9 MB | ############################################################################ | 100%
ca-certificates-2017 | 489 KB | ############################################################################ | 100%
tk-8.6.7 | 3.5 MB | ############################################################################ | 100%
setuptools-38.4.0 | 540 KB | ############################################################################ | 100%
matplotlib-2.2.2 | 6.5 MB | ############################################################################ | 100%
six-1.12.0 | 21 KB | ############################################################################ | 100%
openssl-1.0.2n | 5.4 MB | ############################################################################ | 100%
pyqt-5.6.0 | 4.5 MB | ############################################################################ | 100%
zlib-1.2.11 | 236 KB | ############################################################################ | 100%
tornado-5.1.1 | 665 KB | ############################################################################ | 100%
sqlite-3.22.0 | 907 KB | ############################################################################ | 100%
cycler-0.10.0 | 8 KB | ############################################################################ | 100%
Preparing transaction: done
Verifying transaction: failed
RemoveError: 'requests' is a dependency of conda and cannot be removed from
conda's operating environment.
RemoveError: 'setuptools' is a dependency of conda and cannot be removed from
conda's operating environment.
In reference to the instructions here - https://enigma.co/catalyst/install.html#installing-with-conda
Upvotes: 84
Views: 94925
Reputation: 245
You might not be able to alter the base env, for me, I simply switch to the env that I created and it worked without any other modification.
Upvotes: 0
Reputation: 99
I had to do the following steps to get it to work for me
conda update --force conda
This will run and update conda then run the following command
conda update conda
At each stage update all packages. After that, everything should work fine.
Upvotes: 5
Reputation: 1928
For me, deactivating the current conda environment solves the problem, i.e. run conda deactivate
before upgrading.
Upvotes: -1
Reputation: 1029
I had the same problem on Mac Mojave, and in my case run conda update --force conda
first worked for me.
Upvotes: 102
Reputation: 1
I had solved the problem RemoveError: 'setuptools' is a dependency of conda and cannot be removed from conda's operating environment.
As the following way:
and then check tools
I haven't met any mistakes yet, but help me correct my way , if something wrong, please
Upvotes: 0
Reputation: 11
try conda env create --force -f python3.6-environment-windows.yml I'm not sure exactly where to place it but I use the --force whenever I run into issues like this like conda update --force conda or conda install --force ... use it as last solution since it force conda to perform the command and you might run into some issues later on
Upvotes: 0
Reputation: 81
conda update --force conda
this worked for me in win64 when I
conda install -c https://conda.anaconda.org/sdvillal openslide-python
Upvotes: 8
Reputation: 2859
Silly point to make here but I've been caught by this before: you may not be in the environment you think you are. Just before killing off any package run a quick check to see:
conda env list
Performing ops on the base environment can cause issues, so you may want to create or change environment.
Upvotes: 5
Reputation: 141
This worked for me on Linux:
Uninstall the package via pip:
pip uninstall setuptools
Reinstall using the following command:
conda install -c anaconda setuptools
Consider also that system packages (python3-setuptools
, python-setuptools
in Ubuntu) might need to be removed.
Upvotes: 13
Reputation: 341
conda update --force conda
will solve : Verifying transaction: failed Remove Error: 'request' is a dependency of conda and cannot be removed from conda is operating environment.
Upvotes: 19
Reputation: 21
I had the same problem. Try to use the command prompt to install wheel file if you get an error something like this(as shown in picture) then you must install that wheel file:
Extra(how to install wheel file from command prompt):
- download wheel file as per the system specifications: -search required file here https://www.lfd.uci.edu/~gohlke/pythonlibs/ -e.g. bsddb3 -click bsddb3 and search required file
- open command prompt on your system
- change the location on the command prompt to: where you have downloaded wheel file e.g C:\Users\Name\Downloads
- go to the location, where you have installed python>>go to script>> copy the path (e.g C:\Program Files (x86)\Python36-32\Scripts)
- write the command, to install wheel file using pip install (e.g. C:\Program Files (x86)\Python36-32\Scripts\pip install copy_name_of_the_wheel_file)
- run the command
Upvotes: 1
Reputation: 56
I ran into the same problem, on macos, after removing all R packages installed by anaconda. Unfortunately, the only solution I found is to reinstall anaconda. Alternatively, you could download miniconda shell script installer, run it with -U
option and point the installer at your conda directory. This fixed the issue for me while maintaining settings such as channel priority. However, many of previously installed packages were not importable (Python couldn't find them) and i ended up re-installing all of them.
Upvotes: 1
Reputation: 42
I had the same problem, which was due to a bad installation of a package (OpenEXR in my case).
Try to verify your package with conda list yourPackage
.
If you find which one it is, prefer installing it with pre-built packages here : https://www.lfd.uci.edu/~gohlke/pythonlibs/.
A stack-overflow thread that helped me : Python 2.7, PIP: "Failed building wheel for ..."
EDIT : Two friends had the same error, one solved it by installing/executing with admin rights. The other one succeeded by creating a new virtual environnement for python.
Upvotes: 1