philc / philc/vimium

Regression in recent version of Brave: 'x' closes random tabs in other windows

Open
#4,745 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
27k
Forks
2.6k
PR merge metrics
No merged PRs in 30d

Description

Describe the bug

After recent Brave update (also the previous on from Jul 25), when I attempt to use 'x' to close the current tab, sometimes an unrelated tab in a different window is closed instead.

To Reproduce

Should be clear from the description above. I guess having at least three windows with at least three tabs in each would help, so one has enough tabs to try closing from different windows to be able to easily reproduce.

Browser and Vimium version

Brave | 1.80.125 Chromium: 138.0.7204.184 (Official Build) (arm64)
Revision | 79b2c43a506d75eb2978685ba92ec881f4f1e82f
OS | macOS Version 15.6 (Build 24G84)

Vimium 2.3

It is a clear regression in the browser, so I am not sure it is worth "fixing" instead of waiting it out,
that's why I don't submit a PR. But in case it will help someone, here's a fix that works around the problem for me: https://github.com/tobez/vimium/tree/fix-cross-window-tab-closure-brave - the fix involves using explicit window id for chrome.tabs.query() instead of the current { currentWindow: true } filter, and it will work equally well in those Chromiums that are not broken in this regard. If you want a proper PR, just say the word.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the tab-closing path that calls chrome.tabs.query() using the currentWindow filter, then compare it with the fix-cross-window-tab-closure-brave workaround mentioned in the issue. Reproduce with multiple windows and tabs in Brave, and consider the work done when closing a tab consistently affects the intended window without regressing other Chromium browsers.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.