TSD plugin won't uninstall. How do I kill the Ghost of the Spaghetti Detective?

What is the problem?

I started using a new webcam with my Octoprint + Spaghetti Detective (TSD) setup, and evidently TSD did not like the webcam and regularly pauses my prints. I don't have time to debug that issue now, so I tried disabling TSD. It still paused my print! So I removed the TSD plugin through the plugin manager (and restarted). Ha! No such luck.

I still see the tab for "Access Anywhere - The Spaghetti Detective" under the plugin menu under settings, though it is no longer seen if I go to the plugin manager. Furthermore I now get loads of this message in my logs:

2021-09-27 13:40:32,005 - octoprint.plugins.thespaghettidetective - WARNING - Plugin not configured. Not sending message to server...

So how do I actually uninstall the plugin? It's not in the plugin manager anymore. How do I murder the ghost of the spaghetti detective?

What did you already try to solve it?

Disable TSD in the plugin manager
Uninstall TSD in the plugin manager
restart

Have you tried running in safe mode?

No

Did running in safe mode solve the problem?

N/A

Systeminfo Bundle

octoprint-systeminfo-20210927144442.zip (3.2 MB)

Additional information about your setup

Octoprint running on Raspberry Pi 3B+ running Ubuntu/Raspbian
Browser is Google Chrome from my Linux Ubuntu workstation
Printer is Monoprice Maker Select IIIP (A Wanhoa Duplicator clone)

Did you restart OctoPrint or the Pi ?

I restarted octopi as requested when I made the changes.

So you restarted the OctoPrint interface, but you didn't actually reboot the Pi. It might be necessary to get rid of any modification TSD applied upon installation.

That fixed it - and I see the problem is that octoprint is unable to actually shutdown the system (and doesn't know it or check).

For some reason the install didn't actually create /etc/sudoers.d/octoprint-service, so it likely tried to reboot and failed.

Thanks!

Ah - actually I was looking at the wrong branch.

The install created /etc/sudoers.d/octoprint-shutdown - but that assumed I was using the user id of 'pi' - which I was not. But I looked at the devel branch and it looks like they've already fixed this bug.