You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit c2d656a
Browse filesBrowse the repository at this point in the historyBrowse files
fix(desktop): pass the launch token as one argument (e2e-inc#2365)
* fix(desktop): pass the launch token as one argument
An app whose environment macOS hides got -E2EDesktopLaunch <token> as two argv entries, and a Chromium browser opened the bare token as a URL. It now gets -E2EDesktopLaunch=<token>. The claim and the sweep read both forms, so an app an older version left running is still swept.
* refactor(desktop): share one spelling of the token argument
Drop the two-entry reader: only one nightly shipped that form. Correct the pending native-driver changeset in place.
* refactor(desktop): look processes up by the launch token alone
processesCarrying took NAME=token, built at four TypeScript call sites, and the driver stripped the name back off to match the argument form. It now takes the token; the driver spells both forms.
Copy file name to clipboardExpand all lines: .changeset/desktop-native-driver.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,4 +4,4 @@
4
4
'@e2e-dev/desktop-darwin-x64': minor
5
5
---
6
6
7
-
**Breaking:** the desktop engine no longer runs agent-desktop. It drives macOS through its own Rust driver, loaded into the test process through NAPI-RS and shipped for each Mac in `@e2e-dev/desktop-darwin-arm64` and `@e2e-dev/desktop-darwin-x64`, which npm installs with the engine. Nothing is downloaded on the first run, and the `desktop({ binary })` option is gone: remove it from your config. Keys and typing now reach an app in the background, so `press` and the keyboard capability no longer need `headed: true`. Without `headed`, a `ControlOrMeta` shortcut reaches only the app's menu bar, so Copy, Paste, and Select All still need `headed: true`. An open context menu or pop-up menu is read as part of its window, and a row scrolled out of its list reads as hidden. `desktop.press(key)` presses a key into an app with no control that takes keyboard focus, and `getAttribute` reads a node's `label` and `identifier`. Apple's own apps, Mac App Store apps, and builds signed with `restrict`, whose environment macOS hides, can be launched by `appPath` as well as by `bundleId`; they get `-E2EDesktopLaunch <token>` as their last launch arguments, which is how the engine finds the copy it launched. On Windows and Linux, a run that includes a desktop target now stops with `UNSUPPORTED_CAPABILITY` instead of `INVALID_CONFIG`: the config is valid, and the engine does not support the OS.
7
+
**Breaking:** the desktop engine no longer runs agent-desktop. It drives macOS through its own Rust driver, loaded into the test process through NAPI-RS and shipped for each Mac in `@e2e-dev/desktop-darwin-arm64` and `@e2e-dev/desktop-darwin-x64`, which npm installs with the engine. Nothing is downloaded on the first run, and the `desktop({ binary })` option is gone: remove it from your config. Keys and typing now reach an app in the background, so `press` and the keyboard capability no longer need `headed: true`. Without `headed`, a `ControlOrMeta` shortcut reaches only the app's menu bar, so Copy, Paste, and Select All still need `headed: true`. An open context menu or pop-up menu is read as part of its window, and a row scrolled out of its list reads as hidden. `desktop.press(key)` presses a key into an app with no control that takes keyboard focus, and `getAttribute` reads a node's `label` and `identifier`. Apple's own apps, Mac App Store apps, and builds signed with `restrict`, whose environment macOS hides, can be launched by `appPath` as well as by `bundleId`; they get `-E2EDesktopLaunch=<token>` as their last launch argument, which is how the engine finds the copy it launched. On Windows and Linux, a run that includes a desktop target now stops with `UNSUPPORTED_CAPABILITY` instead of `INVALID_CONFIG`: the config is valid, and the engine does not support the OS.
thrownewEngineError('ENGINE_FAILURE',`could not tell whether a launch of ${pending.target} started the app: looking for its token among the processes failed; quitting tries again`,{retryable: false});
if(carriers===null)thrownewEngineError('ENGINE_FAILURE',`could not tell whether process ${pid} is still the app the engine launched; quitting tries again`,{retryable: false});
0 commit comments