I'm running certbot on my development machine for testing.
I've had it install for some time and it normally works fine.
Today (after not using it from some weeks/months) it is broken.
When I run the certbot command it produces:
certbot
Traceback (most recent call last):
File "/home/XXXX/.local/bin/certbot", line 5, in <module>
from certbot.main import main
ModuleNotFoundError: No module named 'certbot'
If I run dwhich I find several copies of certbot on my path:
Found at: /home/XXX/.local/bin/certbot
Found at: /usr/bin/certbot
Found at: /bin/certbot
I'm not a python guy and I don't recall how I installed certbot except to say the 'apt' version didn't work (and isn't installed) as its on like version 0.4 and I have a feeling I had todo something with python profiles(?).
What is the recommended way to install certbot on ubuntu and how do I remove these bad versions?
OS:
Linux 5.15.0-41-generic #44-Ubuntu SMP Wed Jun 22 14:20:53 UTC 2022
I can login to a root shell on my machine (yes or no, or I don't know): yes
Those are (were) probably symbolic links to other resources, which you can check using the ls -l command. You should be able to check this for the now-renamed certbot objects. If those are indeed symlinks to resources that are now removed due to your previous uninstall commands, you can also safely remove those now-defunct, renamed symlinks. If they're not symlinks, well, that's another story then.