current get_pip requires distutils.util - ubuntu18.04
See original GitHub issuecan the install of this not be done in the script?
/usr/bin/python3.6 get-pip.py --upgrade --force-reinstall
Traceback (most recent call last):
File "get-pip.py", line 21492, in <module>
main()
File "get-pip.py", line 197, in main
bootstrap(tmpdir=tmpdir)
File "get-pip.py", line 82, in bootstrap
import pip._internal
File "/tmp/tmp2eupwih9/pip.zip/pip/_internal/__init__.py", line 40, in <module>
File "/tmp/tmp2eupwih9/pip.zip/pip/_internal/cli/autocompletion.py", line 8, in <module>
File "/tmp/tmp2eupwih9/pip.zip/pip/_internal/cli/main_parser.py", line 8, in <module>
File "/tmp/tmp2eupwih9/pip.zip/pip/_internal/cli/cmdoptions.py", line 14, in <module>
ModuleNotFoundError: No module named 'distutils.util'
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:8 (1 by maintainers)
Top Results From Across the Web
ModuleNotFoundError: No module named 'distutils.util'
The module not found likely means the packages aren't installed. sudo apt-get install python3-distutils sudo apt-get install python3-apt.
Read more >How to install python-distutils for old python versions
It's very, very easy to get pip working with python3.8 on Ubuntu 20.04. It is, so far, impossible to get it working with...
Read more >How to install pip without root access in Ubuntu > 18.04 ...
I would like to install pip within any of my virtual environments created with venv , but the get-pip.py script requires the distutils...
Read more >modulenotfounderror: no module named 'distutils.util'
If the problem is still exist, you need to try to install the python distutils. ... pypa/get-pipcurrent get_pip requires distutils.util - ubuntu18.04#44.
Read more >Docker – install python 3.7 in ubuntu 18.04 without having python ...
This would fail as python3.7-pip doesn't seem to exist; only python3-pip does, which is what installs python 3.6 for some reason. I tried...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hello, I have the same issue, trying to use get-pip.py with python3.6 and having the same error :
ModuleNotFoundError: No module named 'distutils.util'
So I try to run the command :
sudo apt install python3-distutils
But that’s telling me that will install python3.7
So how does it works ? Does I need to install python3.7 to install pip for python3.6 ?
Thanks.
Thanks for filing this!
As you noticed, Ubuntu ships their Python with a different structure, omitting parts of the standard library that pip depends on.
The best course of action here is to voice this concern and provide feedback to Ubuntu about this.
Oh, and
apt install python-distutils
. 😉