Keyboard/pen shortcuts not working

Type of device* : Laptop
Brand and version of the device: Lenovo Ideapad 320
System** : Windows 10

* graphics tablet/display tablet/2-in-1 laptop/Android tablet
** Windows/Linux/Mac/Android, + version (you’ll find it in Help -> Show system information for bug reports)

Hi, when I try to use Krita some of the keyboard/pen shortcuts stop working, like the spacebar, shift, and Ctrl for example, also when this starts to happen I can’t change the brush size, layer opacity and brush opacity by sliding the bar, just by typing the numbers. I thought it was a problem on the laptop’s keyboard, which is not working very well, but now I’m using a USB keyboard and I have the same problem. Also, when I click on any layer the spacebar and some other shortcuts starts working again, but if I press shift, it stops working and I have to click on any layer to make it work again. Another thing that’s weird is that when these bugs are happening I can use the spacebar, shift etc normally when changing the layer names, it’s just the shortcuts that doesn’t work. These bugs start to happen randomly, some times krita just works normal, and I’m not having this trouble with any other drawing software.