[Bug]: External links always open in the same window instead of the last active window (Wayland, niri)

Open
#454 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
linux
Domain
desktop

Research direction

Start by tracing how the Linux app receives URLs from helium.desktop and selects an existing window, then inspect where window activation order is updated for Wayland focus changes. Reproduce with multiple windows and profiles on Wayland using the steps in the report. Done means links open in the most recently focused window and its profile.

Written by the indexing model from the issue text.

Description

bug
Version

0.21.1.1

Have you tested that this is not an upstream issue or an issue with your configuration?
  • I have tried reproducing this issue in Chrome and it could not be reproduced there
  • I have tried reproducing this issue in ungoogled-chromium and it could not be reproduced there
  • I have tried reproducing this issue in Helium with a new and empty profile using --user-data-dir command line argument and it could not be reproduced there
Description

On Wayland (niri), URLs opened from other apps always go to the same browser window, regardless of which Helium window was last focused.

How to Reproduce?
  1. Run Helium natively on Wayland (niri compositor, --ozone-platform-hint=auto).
  2. Open two or more browser windows (same profile is enough).
  3. Focus window B (click into it), then switch to another app.
  4. From that app, open a link (xdg-open https://example.com), which hands the URL to the running instance ("Opening in existing browser session.").
  5. Repeat with window C focused.
Actual behavior

The link always opens as a new tab in the same window (the oldest window of the Default profile), no matter which window was focused last. Focusing a window in a second profile ("Work") also doesn't change anything: profile.last_used in Local State stays "Default" after focusing each window for 13+ seconds, so the window activation order never seems to update.

Test log (window IDs from niri msg windows):

Focused window Profile Link opened in
14 Default 14
16 Work (Profile 1) 14
15 Default 14
Expected behavior

The link opens in the most recently active Helium window (and its profile), as it does on macOS.

Additional context
  • OS: NixOS 26.11 (unstable), kernel 6.12.114
  • Compositor: niri unstable 2026-08-02 (feb3e43)
  • GPU: NVIDIA GTX 1050 Ti, driver 580.x
  • Helium runs as a native Wayland client (no XWayland windows), launched with --enable-features=AcceleratedVideoDecodeLinuxGL,...
  • Default URL handler: helium.desktop (Exec=helium ... %U)
  • The window activation order (used to choose the target window for incoming URLs) appears not to be updated from Wayland activation/focus changes on this compositor.
Dominant language
Shell
Stars
1.1k
Forks
63
Avg merge
28m
Merged PRs (30d)
11

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No 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.

More from imputnet/helium-linux

All issues in imputnet/helium-linux

Similar issues

More Shell/Bash issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.