Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about Collectives
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about Teams
After I run the
conda env create -f environment.yml
in Conda, I receive the following warning:
Warning : you have pip-installed dependencies in your environment file, but you do not list pip itself as one of your conda dependencies...
What does this mean and what should I be doing instead?
When creating an environment the warning disappeared by including
- pip
explicitly in the yaml file. Yes, it is a bit awkward because if your environment has pip packages you already have declared that you used pip packages with
- pip:
The yaml file would look like:
# Packages omitted for simplicity
name: myenv
channels:
- anaconda
- conda-forge
- defaults
dependencies:
- python
- scipy
- pip
- pip:
- datetime
At the time of creating a new environment from scratch this warming can be avoided by explicitly installing pip, for instance with: conda create -n env_with_pip python=3.7 numpy pip
–
In your environment yml file under list of the packages you install through conda you must also add pip as a package to be installed. This installs the pip, and so your pip packages can be installed using this pip.
Previously pip was shipped with conda but now we have to explicitly install pip when using conda
–
–
–
–
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.