Traceback (most recent call last): File "/usr/lib/command-not-found", line 28, in <module> from CommandNotFound import CommandNotFound File "/usr/lib/python3/dist-packages/CommandNotFound/CommandNotFound.py", line 19, in <module> from CommandNotFound.db.db import SqliteDatabase File "/usr/lib/python3/dist-packages/CommandNotFound/db/db.py", line 5, in <module> import apt_pkg ModuleNotFoundError: No module named 'apt_pkg'
sudo apt-file search apt_pkg.so
cd /usr/lib/python3/dist-packages ls -l apt_pkg.cpython* sudo ln -s apt_pkg.cpython-38-x86_64-linux-gnu.so apt_pkg.so sudo apt-get update