microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.75k stars 29.46k forks source link

When pressed 3 more keys for shortcuts, VS Code ignores w/ "Ignoring single modifier meta due to it being pressed together with other keys." #210106

Closed c3-johnreddyzhang closed 7 months ago

c3-johnreddyzhang commented 7 months ago

I noticed that the VS Code command palette is not opening, using debugger and pressing cmd + shift + p, I get the following output: the last key press is ignored and does not open the panel.

2024-04-10 14:43:47.237 [info] [KeybindingService]: / Soft dispatching keyboard event 2024-04-10 14:43:47.237 [info] [KeybindingService]: \ Keyboard event cannot be dispatched 2024-04-10 14:43:47.237 [info] [KeybindingService]: / Received keydown event - modifiers: [shift], code: ShiftLeft, keyCode: 16, key: Shift 2024-04-10 14:43:47.237 [info] [KeybindingService]: | Converted keydown event - modifiers: [shift], code: ShiftLeft, keyCode: 4 ('Shift') 2024-04-10 14:43:47.238 [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase. 2024-04-10 14:43:47.283 [info] [KeybindingService]: / Soft dispatching keyboard event 2024-04-10 14:43:47.284 [info] [KeybindingService]: \ Keyboard event cannot be dispatched 2024-04-10 14:43:47.284 [info] [KeybindingService]: / Received keydown event - modifiers: [shift,meta], code: MetaLeft, keyCode: 91, key: Meta 2024-04-10 14:43:47.284 [info] [KeybindingService]: | Converted keydown event - modifiers: [shift,meta], code: MetaLeft, keyCode: 57 ('Meta') 2024-04-10 14:43:47.285 [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase. 2024-04-10 14:43:47.777 [info] [KeybindingService]: + Ignoring single modifier meta due to it being pressed together with other keys.

Does this issue occur when all extensions are disabled?: YES

VSCode Version: 1.88.0 (Universal) Commit: 5c3e652f63e798a5ac2f31ffd0d863669328dc4c Date: 2024-04-03T13:28:18.899Z (1 wk ago) Electron: 28.2.8 ElectronBuildId: 27744544 Chromium: 120.0.6099.291 Node.js: 18.18.2 V8: 12.0.267.19-electron.0 OS: Darwin x64 23.0.0

Steps to Reproduce:

  1. Open VSCode
  2. Press Cmd+Shift+P
  3. No command palette opens
ulugbekna commented 7 months ago

Thanks for filing the issue.

There must be another program that's capturing the "cmd+shift+p" keybinding.

Could you please press the keyboard shortcuts that you mentioned (working & not working) on this website and send the screenshot? https://w3c.github.io/uievents/tools/key-event-viewer.html

(as a workaround, you can use F1 to invoke the palette for now)

c3-johnreddyzhang commented 7 months ago

Thank you @ulugbekna ! Here is the cmd + p key press that works:

Screenshot 2024-04-16 at 3 42 18 PM

Here is the cmd + shit + p key press that does not work: it registered shift and meta, but then pressing "p" does not do anything.

Screenshot 2024-04-16 at 3 44 53 PM

I tried some other combinations and some random ones registered 3 key presses.

Screenshot 2024-04-16 at 3 41 41 PM

Looks like cmd+shift+p is captured by something that is not clear... Given this, is there a way I can find out what program is capturing the keybinding?

c3-johnreddyzhang commented 7 months ago

Update: Thanks to the suggestion, I was able to find which app is capturing the shortcut globally and disabled that. Now it works as expected!

For context, the app that captured it is Tick Tick, short cut is to start tomato clock. The app to find this is called "ShortcutDetective".