Skip to content

fix(service): open the dashboard over WebDriver, not the devtools protocol - #422

Merged
vishnuv688 merged 2 commits into
mainfrom
fix/launcher-without-devtools-protocol
Oct 7, 2026
Merged

vishnuv688 merged 2 commits into
mainfrom
fix/launcher-without-devtools-protocol

Conversation

@vishnuv688

Copy link
Copy Markdown
Member

What & why

The launcher opened the dashboard window with remote({ automationProtocol: 'devtools' }). That protocol is implemented by the devtools package, so the service declared devtools ^8.42.0 as a peer, and npm installed it together with puppeteer-core@21 into every project that added the service.

On WebdriverIO 10 this breaks the dashboard. A fresh create-wdio@10.0.1 project that selects the devtools service works only while npm happens to auto-install that peer. Without it (for example after npm i --legacy-peer-deps), onPrepare fails with:

Error: Type check for option "automationProtocol" failed: Couldn't find automation protocol "devtools": Cannot find package 'devtools'

The tests still run, but no dashboard window opens.

The launcher now opens the window over WebDriver, through the same chromedriver the test sessions already resolve, and devtools is no longer a peer:

  • launcher.ts: drop automationProtocol: 'devtools'; quiet the webdriver logger instead of devtools while polling for the window to close.
  • constants.ts: hide the "controlled by automated test software" bar with chromedriver's excludeSwitches: ['enable-automation'] instead of the Puppeteer-only wdio:devtoolsOptions.ignoreDefaultArgs.
  • package.json: remove the devtools peer. The lockfile change is only that importer entry.
  • Changeset: patch for @wdio/devtools-service.

Type of change

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Polish (an improvement to an existing feature)
  • Breaking change (existing behavior changes for users)
  • Documentation
  • Internal (build, CI, dependencies, tooling)

Packages touched

  • shared (types and contracts)
  • core (framework-agnostic capture/reporting)
  • elements (published element/snapshot API — @wdio/elements)
  • service (WebdriverIO adapter)
  • nightwatch-devtools (Nightwatch adapter)
  • selenium-devtools (Selenium adapter)
  • selenium-devtools-py (Selenium Python adapter)
  • backend (server)
  • app (UI)
  • script (page-injected runtime)
  • trace (Trace mode)

Notes for reviewers

  • Verified end-to-end on WebdriverIO 10, which CI cannot do (it needs a real browser). A fresh create-wdio@10.0.1 project (mocha, @wdio/* 10.0.1) with this branch's service, backend, script, elements and app packed and installed with plain npm install: devtools and puppeteer-core@21 are no longer installed, the dashboard opens with no automation bar, the login spec passes with its actions, console and network captured, and closing the window ends the run.
  • Lockfile: letting pnpm regenerate it re-resolved unrelated peers (the WDIO example moved from webdriverio 9.32.0 to 9.30.1), so only the three-line devtools entry under packages/service is removed. pnpm install --frozen-lockfile passes.
  • Follow-up, not in this PR: nightwatch-devtools opens its dashboard the same way (run-lifecycle.ts) and has the same devtools peer. It still works because that adapter depends on webdriverio ^9; it should get the same change before it moves to v10. Kept out to hold this PR to one adapter.
  • Release note: this complements the unreleased accept-webdriverio-v10 and share-the-projects-wdio-packages changesets. Together they are what a create-wdio@10 project needs to install the service without workarounds.

pnpm build, pnpm test (2500 passed), pnpm typecheck and pnpm lint (0 errors) are green locally.

Screenshots / recordings

Not a UI change. The dashboard window looks the same as before; only how it is launched changed.

…tocol

automationProtocol 'devtools' needs the devtools package, so the service
declared devtools ^8.42.0 as a peer and npm installed it, plus an old
Puppeteer, into every project. On WebdriverIO 10 the dashboard window
failed to open when it was absent. chromedriver is already resolved for
the test sessions, so the launcher uses it too.
@greptile-apps

greptile-apps Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

RetriggerConfidence Score: 5/5

[Medium risk] Changes how the dashboard window launches in the service.

The PR appears safe to merge, with the previous finding fixed and no new actionable issue found.

Summary

The PR opens the dashboard through WebDriver and removes the service’s devtools peer.

  • Chrome’s automation bar is hidden with excludeSwitches.
  • Tests check the launch options.
  • The latest change fixes the outdated launch comment and types DEFAULT_LAUNCH_CAPS directly.

Reviews (2) · Last reviewed commit: "fix(service): describe the WebDriver lau..." · Reviewed by Greptile

Comment thread packages/service/src/constants.ts
The comment still said the dashboard used the devtools protocol and had
to hide the infobar with ignoreDefaultArgs, inviting someone to undo the
excludeSwitches setting. The cast it justified is no longer needed.
@vishnuv688
vishnuv688 merged commit b191b5b into main Oct 7, 2026
11 checks 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