python Tor nyx ModuleNotFoundError: No module named 'distutils.pawn' at Ubuntu 18.04

Question:

File "/usr/bin/nyx", line 11, in <module>
    load_entry_point('nyx==2.0.4', 'console_scripts', 'nyx')()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 480, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2693, in load_entry_point
    return ep.load()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2324, in load
    return self.resolve()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2330, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/usr/lib/python3/dist-packages/nyx/__init__.py", line 46, in <module>
    import distutils.spawn
ModuleNotFoundError: No module named 'distutils.spawn'

i tried to execute "nyx" command. I use ubuntu 18.04 in my Secure shell.

Asked By: Mehmet Aydınlar

||

Answers:

Did you install venv on your system?

If not, try the following:

sudo apt install python3.x-venv

x represents the version number. If using Python 3.11, the command will look as follows:

sudo apt install python3.11-venv
Answered By: Stanley Ulili
Categories: questions Tags: ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.