-
Notifications
You must be signed in to change notification settings - Fork 301
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ModuleNotFoundError: No module named 'distutils.cmd' #124
Comments
Same here, also on Debian |
Also got this error on Debian 10 Buster, Python 3.7.3. |
Same on Ubuntu 20.04, Python 3.9.5 |
It's likely because you're on a system that does not install the |
Sadly, on Ubuntu 20.04, Now, I see why it 'worked' before, it was Python 3.8 |
After manually adding
This is caused by Could you update |
pip (which get-pip.py uses) installs itself in the directory advertised by the interpreter used to run it. With pip moving to rely on |
A better check would actually be |
In general, if you're outside of a Python virtual environment, you should invoke pip as |
As I mentioned before, the issue is caused by |
It would certainly make sense for pip to trigger a warning if it ends up installing packages outside of its Again, your interpreter seems to be misconfigured, advertising an installation scheme not included in its |
As additional options, you could try |
That will be helpful! 👍
It is what Ubuntu 20.04 package
|
Flag
Flag
Could you update #usage of README.md document including description of all |
I believe this is a bug in Debian's Python package. Their modifications to Python have been a source of a long standing debate: https://gist.github.com/tiran/2dec9e03c6f901814f6d1e8dad09528e has a lot of discussion. One of the pip maintainers has already filed an issue for Python 3.10 distutils/sysconfig -- https://bugs.launchpad.net/ubuntu/+source/python3.10/+bug/1940705. I strongly recommend filing an issue with Debian and Ubuntu for this -- while pip can do things to paper over the issue, the fundamental problem is that the Python installation is not proper. Part of the problem is that Debian users don't ask Debian's maintainers to make fixes for the things they break.
How did you do this? If you've used what is available in CPython's source tree, then you've installed an incompatible distutils for the Python interpreter -- Debian relies on patches they make to distutils to keep things working. |
I think that is the issue, Ubuntu packages are inconsistent, i.e. All Ubuntu provided Python3.[89] 'installations' have
I will consider that.
Installing might be a bit of overstatement, since I am working with Docker container I am doing:
I would do |
Okay, so it's confirmed that this is caused by Debian's patches to Python. They break out Closing this, since I don't think we can do anything about this on our end. If someone has ideas, please go ahead and let us know in a new issue. :) |
Workaround worked for me:
|
Hi @PawelZ-RD , |
/cc @doko42 |
😭 Why Debian, Why Python? Why? |
https://bugs.launchpad.net/ubuntu/+source/python3.10/+bug/1940705
|
if you get this error |
This solved it for me:
|
Please report this as a bug to Debian and Ubuntu, if it has not been reported already. |
pip installation on Debian 11 via get-pip.py
python 3.9.2
The text was updated successfully, but these errors were encountered: