Pause Until detects state, not events.
You are wanting to detect the event of a key press or a mouse click, not detect the state of whether the key is down or the button is pressed.
By default, in recent versions of Keyboard Maestro uses a Reduced CPU option, which means the check is happening less frequently which is why you are seeing the issue more often. You could turn off that option, but really that is just making the issue less prevalent.
The problem is that the Pause Until only checks the state periodically, and you are holding the key/button down momentarily, and unless you hold it down long enough there is no guarantee that the Pause Until will check at the right time.
If you want to detect an event (key press / button press), use a trigger (USB Device Key trigger). Use a macro like this:
- Macro “Detect Key Pressed” (Disabled)
- Trigger on USB Device Key (key pressed or mouse button as desired)
- Set variable "Key Pressed" to "1"
Then instead of your Pause Until, use:
- Set variable “Key Pressed” to “0”
- Enable Macro “Detect Key Pressed”
- Pause Until variable “Key Pressed” is not “0”
- Disable Macro “Detect Key Pressed”
The macro will detect your press no matter how fast it is, and the variable will always be set and the Pause Until will work no matter how slow it checks for the event.