Konda shows two versions of the query library

I am new to cond and see something strange, but I really don’t know if the problem is or not.

I am now in the root environment. At some point, I tried installing pip in a different environment, but accidentally just ran it pip install requests. This seems to have installed it in my root environment:

$ conda list | grep requests
requests                  2.12.4                   py36_0  
requests                  2.13.0                    <pip>

And it looks like the pip version is what you need to get when you run python:

$ python
Python 3.6.0 |Continuum Analytics, Inc.| (default, Dec 23 2016, 12:22:00) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import requests; requests.__version__
'2.13.0'

I assume that if two versions of the same package lie around, this will cause a headache later. Then my assumption was that I would be better off saving the non-pip version, so I tried this:

$ pip uninstall requests
[asks for confirmation, say yes]
$ conda list
[traceback, which I can post if helpful. Summary is:]
ModuleNotFoundError: No module named 'requests'

Then it pip install requestsbrings me back to square 1 (having both versions of the queries).

, , . docs, pip conda, :

  • conda,
  • run pip install whatever
  • conda list .

- conda list --name root, .


, :

  • , requests?
  • , ?
  • pip conda?
+4
1
  • , ?

.

  1. , ?

conda remove, pip uninstall . ( , conda .) - , .../lib/python3.6/site-packages/requests-2.13.0.dist-info. , , .

FWIW, , pip, .

  1. pip conda?

OP . conda pip, . , conda, , pip .

+1

Source: https://habr.com/ru/post/1674196/


All Articles