workbench.action.focusActiveEditorGroup does not move focus from sidebar when triggered via keybinding

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

When the sidebar has focus, workbench.action.focusActiveEditorGroup (and focusFirstEditorGroup) does nothing when triggered via a keybinding. The same command works correctly when run from the Command Palette.
This works correctly in VS Code with the same keybindings.json.

Additional findings:

  • Running workbench.action.focusActiveEditorGroup from the Command Palette while the sidebar is focused works correctly — focus moves to the editor
  • workbench.action.focusFirstEditorGroup has the same issue
  • workbench.action.toggleSidebarVisibility works fine via keybinding from the sidebar, confirming the keybinding is delivered
  • The same keybindings.json works correctly in VS Code
  • workbench.action.focusNextPart errors with: Unknown part workbench.parts.activitybar on layout wb?; have: workbench.parts.statusbar, workbench.parts.editor, workbench.parts.titlebar, workbench.parts.banner, workbench.parts.panel, workbench.parts.auxiliarybar, workbench.parts.sidebar, workbench.parts.unifiedsidebar

Steps to Reproduce

  1. Add this to keybindings.json:
{
  "key": "ctrl+shift+alt+space",
  "command": "workbench.action.focusActiveEditorGroup"
}
  1. Open a file in the editor
  2. Click the sidebar (e.g. File Explorer) so it has focus
  3. Press ctrl+shift+alt+space

Expected Behavior

expected: Focus moves to the editor group
actual: Focus stays in the sidebar. No error.

Operating System

Linux

Version Information

  • Cursor 2.6.21 (fea2f546c979, arm64)
  • VS Code 1.112.0 (works correctly with same keybindings)
  • Fedora Asahi Remix 43
  • Linux 6.18.15-400.asahi.fc43.aarch64+16k

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the thorough report. This is really well documented.

This looks like a bug on our side. Cursor’s layout is different from VS Code. workbench.parts.activitybar is replaced with workbench.parts.unifiedsidebar, and it looks like the focus commands focusActiveEditorGroup and focusFirstEditorGroup don’t properly move focus from the sidebar when they run from a keybinding. Since it works from the Command Palette but not from a keybinding, this looks like a dispatch issue, not a command logic issue.

I’ve flagged this with the team. No ETA yet, but your report helps us prioritize it.

As a workaround, you can try a different way to move focus to the editor:

{
  "key": "ctrl+shift+alt+space",
  "command": "workbench.action.focusNextPart"
}

But like you said, focusNextPart also errors because the activitybar part is missing. Another option is:

{
  "key": "ctrl+shift+alt+space",
  "command": "workbench.action.toggleSidebarVisibility"
}

This will hide the sidebar and return focus to the editor. Press it again to bring the sidebar back. Not perfect, but it works until we fix this.

Let me know if you find anything else that works.

awesome, thanks for the prompt response! I won’t dig into it much more, I can survive without the keybinding for a while :wink: