-
Notifications
You must be signed in to change notification settings - Fork 38.4k
Description
Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: git commit e126c61 (1 Dec 2021), with openvscode-server patches until commit 4a311f9
- Browser: Firefox
94.0+build3-0ubuntu0.20.04.1 - OS Version: Ubuntu 20.04
Steps to Reproduce:
- With a freshly opened window, open or type some text in it.
- Try using Ctrl + Shift + Right, text should be selected at word boundaries.
- Open a terminal, then close it using
exitcommand. - Try using Ctrl + Shift + Right again.
Expected: Text should be selected at word boundaries.
Actual: No text is selected. Cursor doesn't move at all.
This is the the same issue as filed at coder/code-server#3504 [1] and gitpod-io/gitpod#7015 [2]. If it's reproducible in 3 server implementations (counting openvscode-server), then it's probably an upstream issue. Sadly I don't have an access to GitHub Codespaces, so I can't verify it with an "official" implementation [3].
You'll notice in keyboard troubleshooting log below the following 2 lines:
[2021-12-03 01:36:07.151] [window] [info] [KeybindingService]: | Resolving ctrl+shift+[ArrowLeft]
[2021-12-03 01:36:07.155] [window] [info] [KeybindingService]: \ From 2 keybinding entries, matched workbench.action.terminal.resizePaneLeft, when: terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported, source: built-in.
It's been suggested in [1] that vscode might still think that terminalFocus is active despite the terminal is closed. Thus, a workaround I've been using is to have the following in keybinding.json (with default unbind):
{
"key": "ctrl+shift+up",
"command": "workbench.action.terminal.scrollUp",
"when": "terminalIsOpen && terminalFocus && terminalProcessSupported"
},That is, wherever terminalFocus exists, augment it with terminalIsOpen.
[3] I mean, https://vscode.dev/ doesn't have terminals. I've tried using Live Share; that doesn't change. See microsoft/live-share#4528
Keyboard shortcuts troubleshooting. The first keypress is before the terminal is opened. The other two are after it's closed.
Details
[2021-12-03 01:36:00.490] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 17, key: Control
[2021-12-03 01:36:00.503] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 5 ('Ctrl')
[2021-12-03 01:36:00.509] [window] [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
[2021-12-03 01:36:00.513] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 16, key: Shift
[2021-12-03 01:36:00.517] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 4 ('Shift')
[2021-12-03 01:36:00.521] [window] [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
[2021-12-03 01:36:00.808] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 37, key: ArrowLeft
[2021-12-03 01:36:00.813] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 15 ('LeftArrow')
[2021-12-03 01:36:00.817] [window] [info] [KeybindingService]: | Resolving ctrl+shift+[ArrowLeft]
[2021-12-03 01:36:00.821] [window] [info] [KeybindingService]: \ From 2 keybinding entries, matched cursorWordLeftSelect, when: textInputFocus, source: built-in.
[2021-12-03 01:36:01.146] [window] [info] [KeybindingService]: + Ignoring single modifier shift due to it being pressed together with other keys.
[2021-12-03 01:36:03.304] [window] [info] [KeybindingService]: | Resolving [KeyE]
[2021-12-03 01:36:03.310] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:03.401] [window] [info] [KeybindingService]: | Resolving [KeyE]
[2021-12-03 01:36:03.406] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:03.737] [window] [info] [KeybindingService]: | Resolving [KeyX]
[2021-12-03 01:36:03.744] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:03.832] [window] [info] [KeybindingService]: | Resolving [KeyX]
[2021-12-03 01:36:03.838] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:04.210] [window] [info] [KeybindingService]: | Resolving [KeyI]
[2021-12-03 01:36:04.218] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:04.344] [window] [info] [KeybindingService]: | Resolving [KeyI]
[2021-12-03 01:36:04.348] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:04.396] [window] [info] [KeybindingService]: | Resolving [KeyT]
[2021-12-03 01:36:04.404] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:04.518] [window] [info] [KeybindingService]: | Resolving [KeyT]
[2021-12-03 01:36:04.523] [window] [info] [KeybindingService]: \ No keybinding entries.
[2021-12-03 01:36:04.762] [window] [info] [KeybindingService]: | Resolving [Enter]
[2021-12-03 01:36:04.769] [window] [info] [KeybindingService]: \ From 20 keybinding entries, no when clauses matched the context.
[2021-12-03 01:36:04.824] [window] [info] [KeybindingService]: | Resolving [Enter]
[2021-12-03 01:36:04.827] [window] [info] [KeybindingService]: \ From 20 keybinding entries, no when clauses matched the context.
[2021-12-03 01:36:06.677] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 17, key: Control
[2021-12-03 01:36:06.685] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl], code: ControlLeft, keyCode: 5 ('Ctrl')
[2021-12-03 01:36:06.689] [window] [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
[2021-12-03 01:36:06.692] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 16, key: Shift
[2021-12-03 01:36:06.696] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ShiftLeft, keyCode: 4 ('Shift')
[2021-12-03 01:36:06.700] [window] [info] [KeybindingService]: \ Keyboard event cannot be dispatched in keydown phase.
[2021-12-03 01:36:06.766] [window] [error] Cannot refresh property when process is undefined: refreshProperty@http://localhost:3000/static/out/vs/workbench/workbench.web.api.js:1726:20767
refreshProperty@http://localhost:3000/static/out/vs/workbench/workbench.web.api.js:2754:6424
[2021-12-03 01:36:07.142] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 37, key: ArrowLeft
[2021-12-03 01:36:07.147] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 15 ('LeftArrow')
[2021-12-03 01:36:07.151] [window] [info] [KeybindingService]: | Resolving ctrl+shift+[ArrowLeft]
[2021-12-03 01:36:07.155] [window] [info] [KeybindingService]: \ From 2 keybinding entries, matched workbench.action.terminal.resizePaneLeft, when: terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported, source: built-in.
[2021-12-03 01:36:07.913] [window] [info] [KeybindingService]: / Received keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 37, key: ArrowLeft
[2021-12-03 01:36:07.920] [window] [info] [KeybindingService]: | Converted keydown event - modifiers: [ctrl,shift], code: ArrowLeft, keyCode: 15 ('LeftArrow')
[2021-12-03 01:36:07.925] [window] [info] [KeybindingService]: | Resolving ctrl+shift+[ArrowLeft]
[2021-12-03 01:36:07.930] [window] [info] [KeybindingService]: \ From 2 keybinding entries, matched workbench.action.terminal.resizePaneLeft, when: terminalFocus && terminalHasBeenCreated || terminalFocus && terminalProcessSupported, source: built-in.
[2021-12-03 01:36:08.344] [window] [info] [KeybindingService]: + Ignoring single modifier ctrl due to it being pressed together with other keys.