I have tried to use current_key to find the key name of the key that is pressed but the problem is that when I give it to the keyboard.block() function, it tell me the following error: ValueError: Can only normalize non-empty string names. Unexpected ''
` def isLimitReached(self):
text = self.sender().toPlainText()
accepted_keys =["left","right","up","down","backspace"]
if len(text) > 508:
if keyboard.get_hotkey_name() not in accepted_keys:
current_key = keyboard.get_hotkey_name()
keyboard.block(current_key)
else:
print(text)`
I have tried to use current_key to find the key name of the key that is pressed but the problem is that when I give it to the keyboard.block() function, it tell me the following error: ValueError: Can only normalize non-empty string names. Unexpected ''
` def isLimitReached(self): text = self.sender().toPlainText()