After upgrading to Ubuntu 20.04 I started receiving this error
ModuleNotFoundError: No module named 'distutils.util' for every
pipcommand I run.
I tried the solutions on ModuleNotFoundError: No module named 'distutils.util' and pip3 is pointing to the wrong version of python but nothing seems to be working.
Tried this:
python3 -m pipand:
sudo apt-get install python3-distutils
sudo apt-get install python3-aptthese two commands are telling me these packages are already installed, so I reintalled them but no light at the end of the tunnel.
Any solution for this?
I have a virtual environment running Python 3.6.9.
3 Answers
In my case, I solved this with
sudo apt install python3.10-distutils 1 I fixed this by installing the version-specific distutils:
i.e.:
sudo apt install python3.9-apt I solved this by creating a new virtual environment running Python 3.8.