this is my setup.py file for installing my python program, after the installation using python3 setup.py install
an entry to my program was created named
Instead of python3 setup.py install use:
pip3 install .
then
pip3 uninstall abc
This will remove testmain.
I had the same question today and spent the entire morning trying to figure out why the script wouldn't uninstall. Nothing worked until I saw Ramana's answer here: https://askubuntu.com/questions/38692/how-does-one-remove-applications-installed-through-python-setup-py-install
"You should always install Python apps with "pip". pip supports uninstall option." and the example in the commment on how local path is supported.