I mean sure, but I wasn't exaggerating when I said it is probably not usable on other peoples computers. It only works on linux, it doesn't work on wayland, and because I am using xinput to disable the keyboard, you will have to replace the device name in blockKeyboard.py:
https://github.com/TT-392/keyAlarm/tree/master
It shouldn't be too difficult to write your own though, so, if anyone wants to do so, feel free to steal the idea.