search

Home  >  Q&A  >  body text

python-pip - Switch the python version under win10. The library python3 installed by pip for python2.7 cannot be used. Please tell me how to switch the Python version freely.

There are two versions of Python installed in win10, but the libraries installed by pip cannot be shared, and the versions installed by pip cannot be switched. I want to know how to solve it! ! !

为情所困为情所困2724 days ago2096

reply all(3)I'll reply

  • 扔个三星炸死你

    扔个三星炸死你2017-07-05 11:04:01

    The answer given by the above respondent is wrong, you can read the article I wrote

    reply
    0
  • 过去多啦不再A梦

    过去多啦不再A梦2017-07-05 11:04:01

    If the original Python version is Python2.7, then all the libraries we installed under Python2.7 are stored in the ...Python27Libsite-packages directory. The same is true for Python3.5 site-packages directory, you can try to copy the libraries in the 2.7 directory to the site-packages directory of 3.5.

    Be careful here, because Python2 and 3 are very different, and many third-party libraries are not publicly available, so after you copy them, some libraries may have problems and cannot be used. You must be mentally prepared for this. .

    reply
    0
  • 给我你的怀抱

    给我你的怀抱2017-07-05 11:04:01

    Use virtualenv to create an independent environment

    reply
    0
  • Cancelreply