When entering shell command does not exist in ubuntu16.04, the error ModuleNotFoundError solutions

BACKGROUND: get the ubuntu machine, I installed the 3.7 version of python on your system, deleting a file lsb_release.py during the installation process, after my shell commands on the use of the anomaly.

Error triggered reason

When I enter the command ubuntu unrecognized when it should normally prompt similar command not foundwords and the like, but the system does report the following errors:

Error details:

Traceback (most recent call last):
  File "/usr/lib/command-not-found", line 27, in <module>
    from CommandNotFound.util import crash_guard
ModuleNotFoundError: No module named 'CommandNotFound'

solution:

sudo apt-get remove --purge python3*
sudo apt auto remove

Reference Links: https://askubuntu.com/questions/766246/missing-package-commandnotfound

Summary: Before deleting system of things to think about before, do not hand cheap! ! !

Guess you like

Origin www.cnblogs.com/finlu/p/11588870.html