Skip to content

fix(launcher): stop relying on --load-extension for Google Chrome - #45

Merged
wolfgang-aura merged 1 commit into
mainfrom
fix/chrome-load-unpacked
Oct 5, 2026
Merged

wolfgang-aura merged 1 commit into
mainfrom
fix/chrome-load-unpacked

Conversation

@wolfgang-aura

Copy link
Copy Markdown
Owner

Refs #44. Branded Google Chrome 137+ ignores --load-extension, and the launcher handed Chrome that flag anyway. The shortcut and -Status reported healthy while the extension never loaded.

Change

  • The launcher detects branded Chrome by VersionInfo.ProductName -eq 'Google Chrome'. Chromium and Chrome for Testing ship a chrome.exe too and still honor the flag.
  • On Chrome it leaves --load-extension out, prints the one-time Load unpacked steps, and still passes --disable-features=CalculateNativeWinOcclusion. -Status checks only that flag, since an unpacked extension does not show on a command line.
  • Auto-pick order is Brave, then Edge, then Chrome. It also looks for a per-user Chrome install.
  • New -ShowLaunchArgs prints the browser and arguments without changing anything.

Verification

  • test/native-host.test.mjs builds stand-in exes for Google Chrome, Chrome for Testing and Edge, and checks the launch arguments of each (Windows only; skipped on CI's Linux runner). Before the fix the test failed with Chrome must not be given --load-extension.
  • On the owner's real Brave: -Status exits 0 and -ShowLaunchArgs still includes --load-extension.
  • Not verified against a real Chrome 137+. Chrome is not installed here.

🤖 Generated with Claude Code

Branded Google Chrome 137+ ignores --load-extension. When the launcher
picked Chrome, its shortcut and -Status looked healthy while the extension
never loaded, and the CLI could not reach the host.

The launcher now detects branded Chrome by product name (Chromium and
Chrome for Testing also ship chrome.exe and still honor the flag). On Chrome
it leaves the flag out, asks for a one-time Load unpacked, keeps the
occlusion flag, and checks only that flag in -Status. Edge is preferred over
Chrome. -ShowLaunchArgs prints what would run, and the native host test
drives it with stand-in browser exes.

Refs #44

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@wolfgang-aura
wolfgang-aura merged commit 9ea5b05 into main Oct 5, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant