ClickGuard is a small Windows tray app that helps with bad mouse double-clicks, phantom inputs and switch bounce.
Install it with ClickGuard-Setup.exe, let it sit in the tray, and change the threshold if you need to. If you close it, you can start it again from the desktop shortcut or Windows Search.
Docs and download page:
If you want to inspect the code or build it yourself, the source is here. Most people should just use the installer from the docs/releases page but anyway