Darktable behaving like stuck key, - mouse not working properly either

I am running Darktable 5.0.1 from the appimage. This morning, Darktable is behaving strangely. After startup (of Darktable), the mouse was not working properly (even on the rest of the computer (running Linux Mint)). Also the keyboard was not responding properly.

Darktable was displaying lots of little pop up message about mouse actions that were undefined, when I tried to use the mouse. When I tried the keyboard, I happened to notice a message

“short keypress resets stuck keys”

Having nothing to lose I tapped a key quickly, and all of a sudden, stuff was back to normal.

I’d blame my hardware (logitech keyboard and mouse) except it is only happening when I first run Darktable.

I restarted everything a couple of times, and it happens each time, with the same fix working.