Skip to content

fix(electron): only pass known Electron releases on as wdio:electronVersion - #693

Draft
goosewobbler wants to merge 1 commit into
mainfrom
fix/electron-version-capability
Draft

goosewobbler wants to merge 1 commit into
mainfrom
fix/electron-version-capability

Conversation

@goosewobbler

@goosewobbler goosewobbler commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Description

WebdriverIO v10 will download Chromedriver from the Electron release named in wdio:electronVersion (goosewobbler/webdriverio#10, not yet upstream). v9 ignores the capability and keeps using browserVersion.

The launcher copied browserVersion into wdio:electronVersion. When browserVersion held a Chromium version, as the "Could not determine the Chromium version for Electron" error advises, or a fork build such as castlabs +wvcus, WebdriverIO v10 would try to download an Electron release that doesn't exist. For a Chromium version, puppeteer's Chrome for Testing fallback then installs a driver at a path the Electron layout doesn't expect, and the cache stays broken for that build.

This change:

  • Sets wdio:electronVersion only for a known release. It must be a version the Electron → Chromium map knows. Anything else keeps to the browserVersion path, which is what v9 uses anyway.
  • Reads an existing wdio:electronVersion first. A value set in the config wins, and a second conversion no longer reads the Chromium browserVersion as the Electron version.
  • Docs: the Chromedriver Configuration section says that with WebdriverIO v10 the driver is the one bundled with the app's Electron release, passed on as wdio:electronVersion.

browserVersion handling is unchanged, so WebdriverIO v9 behaves exactly as before.

Related Issues

Pairs with the WebdriverIO v10 Electron-release Chromedriver work. WebdriverIO no longer guesses whether wdio:electronVersion holds a Chromium version, so the service mustn't put one there.

Type of Change

  • 🐛 Bug fix (non-breaking change which fixes an issue)
  • ✨ New feature (non-breaking change which adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to change)
  • 📖 Documentation update
  • 🎨 Code style/refactoring (no functional changes)
  • 🔧 Internal/tooling change (build scripts, CI, etc.)
  • ⚡ Performance improvement

Scope

  • scope:electron - Electron service and CDP bridge
  • scope:tauri - Tauri service and plugin

Checklist

  • I have read the CONTRIBUTING guidelines
  • My code follows the code style of this project (passes pnpm lint)
  • I have added tests that prove my fix is effective or that my feature works
  • All new and existing tests pass (pnpm test)
  • I have updated the documentation (if appropriate)
  • I have added TypeScript type definitions (if appropriate)
  • My changes generate no new TypeScript errors (pnpm typecheck)

Testing

  • Unit tests added/updated: two new launcher tests, one for a Chromium browserVersion and one for an existing wdio:electronVersion. Two existing tests now expect an unmapped version to stay out of wdio:electronVersion. All four fail without the change. @wdio/electron-service: 555 tests pass, and typecheck, Biome and ESLint are clean.
  • Integration tests added/updated
  • E2E tests added/updated (if applicable)
  • Manually tested on:

Additional Context

  • Diagnostics: the worker diagnostics read wdio:electronVersion, so for a fork build they now skip the informational Electron-version line.
  • Follow-up once WebdriverIO v10 is the minimum (tracked in WDIO v10 support (tracking) #297):
    • The "Electron version must be 26 or higher" guard (launcher.ts) and the hard "Could not determine the Chromium version" error can relax. Both exist because Chrome for Testing has no Chromedriver before 115.0.5763.0, and the Electron release ships its own driver.
    • wdio session can pass the Electron version as wdio:electronVersion instead of browserVersion.

Note: This repository does not backport changes to older versions. All changes target the current main branch.

🤖 Generated with Claude Code

@github-actions

github-actions Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor
Release Preview — no release

No bump label detected.
Note: Add bump:patch, bump:minor, or bump:major to trigger a release.


Updated automatically by ReleaseKit

…ersion

WebdriverIO v10 downloads Chromedriver from the Electron release named in
wdio:electronVersion. The launcher copied browserVersion into it, so a Chromium
version (as the "Could not determine the Chromium version" error advises) or a fork
build reached it too, and WebdriverIO would fetch a release that doesn't exist.

- Set wdio:electronVersion only when the Electron -> Chromium map knows the version.
  Everything else keeps to the browserVersion path, which WebdriverIO v9 uses anyway.
- Read an existing wdio:electronVersion first, so a set value wins and a second
  conversion doesn't read the Chromium browserVersion as the Electron version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@goosewobbler goosewobbler mentioned this pull request Oct 1, 2026
25 tasks
@goosewobbler
goosewobbler force-pushed the fix/electron-version-capability branch from c682f1c to e547801 Compare October 1, 2026 13:49
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