Skip to main content
AI Assist is now on Stack Overflow. Start a chat to get instant answers from across the network. Sign up to save and share your chats.
added 262 characters in body
Source Link
wim
  • 368.2k
  • 114
  • 682
  • 818

On Debian-based distros such as Ubuntu, the distutils package is mostly missing. Only the package root and distutils.version is available. The remaining code has been moved to python3-distutils, which must be installed separately.

The following command should solve the problem in Ubuntu 18.04, 20.04 and 22.04:

sudo apt-get install python3-distutils 

If you're using a specific python3 minor version, different from the distro python3 default, then you may need to install the corresponding minor version of the system distutils package. E.g. for Python 3.10:

sudo apt-get install python3.10-distutils 

reference: Negative Python user experience on Debian/Ubuntu - distutils is stripped down and missing most code.

On Debian-based distros such as Ubuntu, the distutils package is mostly missing. Only the package root and distutils.version is available. The remaining code has been moved to python3-distutils, which must be installed separately.

The following command should solve the problem in Ubuntu 18.04, 20.04 and 22.04:

sudo apt-get install python3-distutils 

reference: Negative Python user experience on Debian/Ubuntu - distutils is stripped down and missing most code.

On Debian-based distros such as Ubuntu, the distutils package is mostly missing. Only the package root and distutils.version is available. The remaining code has been moved to python3-distutils, which must be installed separately.

The following command should solve the problem in Ubuntu 18.04, 20.04 and 22.04:

sudo apt-get install python3-distutils 

If you're using a specific python3 minor version, different from the distro python3 default, then you may need to install the corresponding minor version of the system distutils package. E.g. for Python 3.10:

sudo apt-get install python3.10-distutils 

reference: Negative Python user experience on Debian/Ubuntu - distutils is stripped down and missing most code.

added 357 characters in body
Source Link
wim
  • 368.2k
  • 114
  • 682
  • 818

I know this is an old questionOn Debian-based distros such as Ubuntu, but I just come across the same issue using Python 3distutils package is mostly missing.6 in Ubuntu, Only the package root and I am abledistutils.version is available. The remaining code has been moved to solve it using thepython3-distutils, which must be installed separately.

The following command (this worksshould solve the problem in Ubuntu 18.04, 20.04 and 22.04):

sudo apt-get install python3-distutils 

reference: Negative Python user experience on Debian/Ubuntu - distutils is stripped down and missing most code.

I know this is an old question, but I just come across the same issue using Python 3.6 in Ubuntu, and I am able to solve it using the following command (this works in Ubuntu 18.04, 20.04 and 22.04):

sudo apt-get install python3-distutils 

On Debian-based distros such as Ubuntu, the distutils package is mostly missing. Only the package root and distutils.version is available. The remaining code has been moved to python3-distutils, which must be installed separately.

The following command should solve the problem in Ubuntu 18.04, 20.04 and 22.04:

sudo apt-get install python3-distutils 

reference: Negative Python user experience on Debian/Ubuntu - distutils is stripped down and missing most code.

add detail about ubuntu versions
Source Link
Étienne
  • 5.1k
  • 3
  • 39
  • 67

I know this is an old question, but I just come across the same issue using Python 3.6 in Ubuntu, and I am able to solve it using the following command (this works in Ubuntu 18.04, 20.04 and 22.04):

sudo apt-get install python3-distutils 

I know this is an old question, but I just come across the same issue using Python 3.6 in Ubuntu, and I am able to solve it using the following command:

sudo apt-get install python3-distutils 

I know this is an old question, but I just come across the same issue using Python 3.6 in Ubuntu, and I am able to solve it using the following command (this works in Ubuntu 18.04, 20.04 and 22.04):

sudo apt-get install python3-distutils 
deleted 7 characters in body
Source Link
ettanany
  • 20k
  • 9
  • 49
  • 64
Loading
deleted 431 characters in body
Source Link
ettanany
  • 20k
  • 9
  • 49
  • 64
Loading
Source Link
ettanany
  • 20k
  • 9
  • 49
  • 64
Loading