I'm using VSCode OSS on Arch Linux. I was just reorganizing my C++ project files when I found out that Ctrl
+V
suddenly stopped working. Every other keyboard shortcut works, like copying and saving. I can also paste into my other programs just fine. I tried pressing right-click
+ Paste
but it does nothing. Somehow, Ctrl
+Shift
+V
works and pastes correctly.
I found this and checked the Keyboard Shortcuts settings for any conflicts, and there were none. I disabled all extensions and reloaded the window and it still wouldn't work. I made sure I wasn't pasting into the terminal by accident. I tried closing and reopening VSCode multiple times. I even rebooted.
If it's useful information, I upgraded the system packages a day before this happened, but none of them were code
.
Here are the logs from enabling Developer: Toggle Keyboard Shortcuts Troubleshooting
:
// pressing Ctrl+V
2025-01-28 14:53:38.846 [info] [KeybindingService]: / Soft dispatching keyboard event
2025-01-28 14:53:38.847 [info] [KeybindingService]: \ Keyboard event cannot be dispatched
2025-01-28 14:53:38.847 [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 17, key: Control
2025-01-28 14:53:38.848 [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 5 ('Ctrl')
2025-01-28 14:53:38.848 [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
2025-01-28 14:53:38.980 [info] [KeybindingService]: / Soft dispatching keyboard event
2025-01-28 14:53:38.981 [info] [KeybindingService]: | Resolving ctrl+[KeyV]
2025-01-28 14:53:38.982 [info] [KeybindingService]: \ From 1 keybinding entries, matched editor.action.clipboardPasteAction, when: no when condition, source: built-in.
2025-01-28 14:53:38.982 [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl], code: KeyV, keyCode: 86, key: v
2025-01-28 14:53:38.983 [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl], code: KeyV, keyCode: 52 ('V')
2025-01-28 14:53:38.983 [info] [KeybindingService]: | Resolving ctrl+[KeyV]
2025-01-28 14:53:38.983 [info] [KeybindingService]: \ From 1 keybinding entries, matched editor.action.clipboardPasteAction, when: no when condition, source: built-in.
2025-01-28 14:53:38.983 [info] [KeybindingService]: + Invoking command editor.action.clipboardPasteAction.
2025-01-28 14:53:39.083 [info] [KeybindingService]: + Storing single modifier for possible chord ctrl.
2025-01-28 14:53:39.091 [info] [KeybindingService]: + Clearing single modifier due to other key up.
// pressing Ctrl+Shift+V
2025-01-28 14:55:06.556 [info] [KeybindingService]: / Soft dispatching keyboard event
2025-01-28 14:55:06.591 [info] [KeybindingService]: \ Keyboard event cannot be dispatched
2025-01-28 14:55:06.591 [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 17, key: Control
2025-01-28 14:55:06.591 [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 5 ('Ctrl')
2025-01-28 14:55:06.591 [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
2025-01-28 14:55:06.736 [info] [KeybindingService]: / Soft dispatching keyboard event
2025-01-28 14:55:06.737 [info] [KeybindingService]: \ Keyboard event cannot be dispatched
2025-01-28 14:55:06.738 [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 16, key: Shift
2025-01-28 14:55:06.738 [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 4 ('Shift')
2025-01-28 14:55:06.738 [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
2025-01-28 14:55:06.930 [info] [KeybindingService]: / Soft dispatching keyboard event
2025-01-28 14:55:06.931 [info] [KeybindingService]: | Resolving ctrl+shift+[KeyV]
2025-01-28 14:55:06.932 [info] [KeybindingService]: \ From 4 keybinding entries, no when clauses matched the context.
2025-01-28 14:55:06.932 [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: KeyV, keyCode: 86, key: V
2025-01-28 14:55:06.933 [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: KeyV, keyCode: 52 ('V')
2025-01-28 14:55:06.933 [info] [KeybindingService]: | Resolving ctrl+shift+[KeyV]
2025-01-28 14:55:06.934 [info] [KeybindingService]: \ From 4 keybinding entries, no when clauses matched the context.
2025-01-28 14:55:07.147 [info] [KeybindingService]: + Ignoring single modifier shift due to it being pressed together with other keys.
Okay, I fixed it as soon as I posted the question. Open Command Palette and Preferences: Open Keyboard Shortcuts (JSON)
and keybindings.json
will appear. There was an overridden keybinding for clipboardPasteAction
:
// Place your key bindings in this file to override the defaults
[
...
{
"key": "shift+insert",
"command": "-editor.action.clipboardPasteAction"
},
]
I simply had to change "shift+insert"
to "ctrl+v"
. It must have somehow been modified by the system.