Sudo ln -s /usr/local/bin/pip /usr/local/bin/pip3 Sudo ln -s /usr/bin/python3.6 /usr/local/bin/python3 Then, run the following (this works out-of-the-box on 16.10 and If you're using Ubuntu 16.04 LTS, you'll need to use a PPA: sudo add-apt-repository ppa:jonathonf/python-3.6 # (only for 16.04 LTS) Let's suppose that you have a system running Ubuntu 16.04, 16.10, orġ7.04, and you want Python 3.6 to be the default Python. Of course you can alternatively use python3.6 -m pip as well. Pip 18.0 from /usr/local/lib/python3.6/dist-packages (python 3.6) VerificationĪfter this, pip, pip3, and pip3.6 can all be expected to point to the same target: $ (pip -V & pip3 -V & pip3.6 -V) | uniq You prefer to suppress this warning, use -no-warn-script-location. Consider adding this directory to PATH or, if WARNING: The script wheel is installed in '/home/ubuntu/.local/bin' This may sometimes give a warning such as: Installation without sudo curl | python3.6 -user '/home/someuser/.cache/pip' or its parent directory is not owned by theĬurrent user and caching wheels has been disabled. Pip with sudo, you may want sudo's -H flag. Please check the permissions and owner of that directory. Is not owned by the current user and the cache has been disabled. The directory '/home/someuser/.cache/pip/http' or its parent directory The -H flag is evidently necessary with sudo in order to prevent errors such as the following when installing pip for an updated python interpreter: With regard to installing pip, using curl (instead of wget) avoids writing the file to disk. For python3.8, replace 3.6 with 3.8, but it may also first require the python3.8-distutils package. This answer assumes that you have python3.6 installed.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |