Installers before 679e9cd294 staged hermes.exe/hermes-acp.exe in the
checkout's bin\, untracked. That commit gitignores /bin/ and keeps the
legacy copies on purpose (the update tail only strips their PATH entry),
so they are not product state the update must clean. The OLD Desktop's
pre-update dirty check still lists them, which Clear-HistoricalInstallerChurn
reported as foreign churn from v2026.8.13. Exclude exactly those two paths,
and only when OLD predates 679e9cd2943d; anything else still fails.
Greptile on #156531: making all of profiles/<name>/cache/** advisory also
stopped judging the subdirs hermes_cli/backup.py keeps because nothing can
rebuild them (delivered media, the citations ledger). Only rebuildable cache
entries are advisory now; those subdirs and cache/ itself stay judged.
The predicate also missed the --profiles-dir walk, which passes <name>/...
paths and prefixes profiles/ afterwards. It accepts both shapes now.
The parametrized test (home profiles and --profiles-dir) rewrites the schema
memo (must pass) and deletes a citations ledger (must fail). It fails on main
and on the previous commit, passes here.
The rc.9-v0.23.2 attempt's linux and macos "installer-script -> hermes-update
(v0.23.1 -> HEAD)" legs failed USER-STATE PRESERVATION on exactly one entry:
MODIFIED profiles/e2e-second/cache/schema_columns.json
That file is the session-schema memo hermes_state_schema._parse_schema_columns
writes, keyed by a sha256 of SCHEMA_SQL; any release that changes the session
schema rewrites it. The root home's cache/ is in no judged root, but every
entry under profiles/ is judged, so a profile's cache was. Treat
profiles/<name>/cache/** as advisory (still listed in the report), like the
bundled skills tree.
The new test fails without the change and passes with it.
In rehearsal rc.7-v0.23.2 the Windows x64 upgrade leg found and pressed
App Installer's Update for the first time (#155621), and still failed
with "Native update did not automatically relaunch the new package".
App Installer's log stops at DisplayAppsInfoState: nothing deployed.
The screenshot taken after the press shows why. App Installer 1.26
opened "Warning: Metered Connection. The network you are connected to
is metered. Would you like to proceed? (extra charges may apply)" over
the prompt, with Yes and No. The runner's network is metered, and the
driver never answered.
Confirm-AppInstallerPrompt presses the prompt's Update or Install, then
watches for 20 s (MeteredWarningTimeoutSec) for that warning's Yes, as a
user on a metered network would. Yes counts only after the prompt was
pressed. On an unmetered network the warning never comes, and the
driver goes on after the 20 s. The driver's result JSON lists what it
pressed (appInstallerPressed).
Checked on a Windows 11 x64 VM with App Installer 1.26.510 and its
network set to metered (DusmSvc UserCost 2, cost type Fixed). The same
warning opened over the prompt. The driver's Invoke-Button pressed
Update at 17:56:29 and Yes at 17:56:32, App Installer went to
GoToPreparingDeploymentState at 17:56:32, NEW reported
DeploymentSuccessState at 18:04:39, and App Installer relaunched it
20 s after the package changed.
In rehearsal rc.6-v0.23.2 the Windows arm64 upgrade leg passed with
the any-window lookup from #155329, and the x64 leg failed as in rc.5:
App Installer showed "Update Hermes Agent?" with its Update button, and
the driver reported no dialog.
The runners have different App Installers. arm64 has 1.29.379, a WinUI
desktop app that owns its top-level windows. x64 has 1.26.510, a UWP
app. A UWP app's window is an ApplicationFrameHost frame (class
ApplicationFrameWindow): the top-level window belongs to
ApplicationFrameHost, and only the frame's CoreWindow child belongs to
App Installer. Find-WindowButton looked only at top-level windows owned
by an App Installer process, so on 1.26 it found none.
Get-ProcessWindows now also returns the CoreWindow children that
App Installer owns inside ApplicationFrameWindow frames. A frame around
another app's CoreWindow is never searched.
Checked on a Windows 11 x64 VM with App Installer downgraded to
1.26.510: launching OLD and opening NEW's descriptor showed the prompt
in an ApplicationFrameHost frame (pid 7580) around App Installer's
CoreWindow (pid 2224). main's lookup found no button; this one found
Update in pid 2224, and invoking it through InvokePattern started the
update.
In rehearsal rc.5-v0.23.2 both Windows upgrade legs clicked Update now
and App Installer opened "Update Hermes Agent?" for the NEW version
(its log: update Available, DisplayAppsInfoState). The driver watched
for 120 s, reported "no App Installer dialog appeared", never pressed
Update, and the leg failed 15 min later with "Native update did not
automatically relaunch the new package". The x64 screenshot taken when
the watch ended shows the prompt on screen with its Update button.
The driver looked at the first AppInstaller process and that process's
first top-level window. When OLD launches, Windows runs the package's
update check through App Installer (ms-appinstaller:?checkForUpdates),
and that leaves an App Installer window with no buttons open. The
prompt then opens either in a second process (arm64: two AppInstaller
processes, the dialog in the second) or as a second window of the same
one (x64: one process logged both activations). Reproduced on a
Windows 11 VM with App Installer 1.26.509: after the checkForUpdates
activation, pid 9032 kept a buttonless "App Installer" window and the
prompt opened in pid 6092 with an Install button. Taking the buttonless
process first, the old lookup found nothing.
Find-WindowButton (windows-uia-buttons.ps1) now searches every top-level
window of every AppInstaller process, and the driver uses it. On the
same VM state it found Install in pid 6092.
In rehearsal rc.5-v0.23.2 the macOS upgrade arm got further than ever:
Squirrel.Mac installed 0.23.2 (signature and notarization valid) and
relaunched the app on its own. Six seconds later the arm failed with
"could not discover the relaunched backend's listening port".
The probe looked once, and only among the app's direct children for a
process named like `serve` (or a listener whose parent is the app). At
that moment the relaunched app was still starting: its only backend
process was `python3 -m hermes_cli.main gateway run`, which 0.23.2
starts as a launchd job through osascript, so its parent chain is
osascript -> launchd, not the app.
The probe moves to mac-backend-health.sh. Like the Windows arm, it
polls for up to 180 s, finds processes by executable path under the
payload, and asks each one's TCP listeners for /api/health. Only
processes no older than the relaunched app count: an in-place update
keeps the payload path, so an OLD process there must not answer for
NEW. On timeout it lists the payload processes it saw.
Checked on mini (macOS, /bin/bash 3.2) with the real ps, lsof and curl,
using the signed v0.22.0 app's payload Python: an "old" server started
before the reference process was ignored, and a "new" one that bound 6 s
later was found after 9 s. With only the old one running, the helper
timed out and listed it.
The helper's Remove action piped CheckNetIsolation to Out-Null and returned, and Windows
PowerShell 5.1 ignores a native command's exit code, so a refused removal left the exemption in
place with no sign of it. Remove now re-reads the exemption list and throws when the exemption is
still there, as Add already did.
The leg calls Remove from its finally block, so it catches that error and prints it as a GitHub
Actions warning: a throw there would replace a failed leg's own error and skip the package removal
after it, the same reason evidence collection is guarded in that block.
Reported by Greptile on #155191.
The x64 signed-package upgrade leg failed the same way in rehearsals
rc.1, rc.2 and rc.4 of v0.23.2: Update now opened App Installer, which
showed "Cannot open app package. Reason: Error in parsing the app
package." and never requested the NEW bundle. Its own log names the
cause: fetching http://127.0.0.1:<port>/update.appinstaller fails with
0x80072efd (cannot connect). The windows-2025 runner image ships App
Installer 1.26.510 and gets no Store updates; that version fetches the
descriptor from inside its AppContainer, and Windows keeps AppContainers
off loopback unless they are exempted. The arm64 runner (Windows 11, App
Installer 1.29.379) reaches the same feed. Installs from the public feed
never use loopback, so users are unaffected.
Reproduced on a Windows 11 VM with App Installer 1.26.509: the leg's
descriptor gave the same dialog and 0x80072efd, and no request reached
the feed. With App Installer exempted (CheckNetIsolation LoopbackExempt),
the same descriptor opened "Install Hermes Agent? Version
2026.7600.1335.0" and App Installer streamed the bundle from loopback.
The leg now exempts App Installer for its duration and removes the
exemption in its teardown, only when the leg added it. It fails loudly
when the exemption does not take.
The signed-package upgrade legs end with a desktop chat on NEW
(`desktop-smoke.ts --phase new`), against the same HERMES_HOME the OLD
phase populated. The smoke's seeding guard requires the predicted home
to be empty, so that step can never pass: in rc.4-v0.23.2 the Windows
arm64 leg updated, relaunched, kept its plugins and user state, and then
failed with "Predicted Hermes home C:\a\_temp\hermes-bundled-update\home
is not empty (40 entries); refusing to seed an existing profile". The
macOS leg makes the same call once its update succeeds. No leg reached
this step before, so it never failed in CI.
The post-update phase now admits a populated home when the prediction
is one of the run's own homes (--home or <user-data>/hermes-home), and
refuses any other: a prediction that falls through to a default home
can be someone's real profile. Fresh-install phases keep the emptiness
check.
App Installer writes its own log to
%LocalAppData%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir
(Microsoft's App Installer troubleshooting page; @kvnloo on #155052).
On the Windows 11 x64 test VM, opening a corrupt .msixbundle showed the
"cannot parse" path: App Installer's log recorded "AppsInfo -> Error:
[0x8051100f]" and "Parsing error: corruptFile", while the four AppX logs
held only a fallback 0xC00CEE2D ".appinstaller XML not valid" event.
The collector now copies the files there written since the leg began
into proof/update-evidence/appinstaller-diagnostics and prints up to 20
ERROR lines from the AppInstaller-*.log files to the job log. A missing
directory is reported, not skipped silently. Run against that VM with
App Installer still showing the error, it copied the open log and printed
both lines above.
The new test seeds a DiagOutputDir under a temporary LOCALAPPDATA with a
log from before the leg and one from during it. It fails on the previous
collector; mutants that drop the time filter, drop the ERROR lines or
print every line each fail it.
Get-WinEvent ran with -ErrorAction SilentlyContinue, so a read error left
an empty file and "0 events", the same as a quiet window (Greptile on
#155052). A missing channel is worse: Get-WinEvent -FilterHashtable
throws a terminating EventLogException ("The parameter is incorrect")
that SilentlyContinue does not stop. Inside windows-bundled-e2e.ps1's
try, that aborted the whole collector after the first log, and the job
log said only "collection failed: The parameter is incorrect".
Each log is now read in its own try with -ErrorAction Stop.
NoMatchingEventsFound (how Get-WinEvent reports an empty window) stays
"0 events"; any other error is written to the log's file and the job
log as "could not read: <message>", and the remaining logs are still
read. $events is reset per log, so an aborted query can't reuse the
previous log's records.
The new test drives the real Get-WinEvent at a missing channel and at an
empty window. On the Windows 11 x64 test VM (PowerShell 5.1) it fails
on the previous collector ("collection failed: The parameter is
incorrect") and passes here; mutants that swallow every error, record
the empty window as unread, or drop the reset each fail it.
With Check now fixed (#154956), stable rehearsal rc.2-v0.23.2's x64 leg
reached the update itself: after Update now, App Installer showed "Cannot
open app package. Reason: Error in parsing the app package." for the NEW
bundle on the windows-2025 runner. The arm64 leg (Windows 11 runner)
started downloading the same bundle instead. The artifact held neither
App Installer's version nor the AppX event that names the cause.
When the leg fails, the finally block now runs windows-update-evidence.ps1
into proof/update-evidence before teardown removes the package:
- packages.json: Microsoft.DesktopAppInstaller and the package under test
(version, architecture, status, install location);
- the App Installer processes still running;
- AppxPackaging, AppXDeploymentServer, AppXDeployment and
AppModel-Runtime events since the leg began, one file per log.
The job log gets the package versions, an event count per log, and each
warning or error that names the package, a bundle, a descriptor or the
loopback feed. A collection error is logged and never replaces the leg's
own error.
With Check now fixed (#154956), stable rehearsal rc.2-v0.23.2 reached the
next step for the first time: Update now was clicked and OLD exited, then
both Windows legs threw "OLD Playwright ownership did not release after
native process close" although drive-update.cjs had logged its clean end
two minutes earlier and written nothing to stderr.
Start-Process -PassThru returns a process object with no open handle.
When the process exits before anything opens one, Windows PowerShell 5.1
reads its ExitCode as $null, so `$oldDriver.ExitCode -ne 0` is true for a
driver that exited 0. Reproduced on a Windows 11 26H2 VM under
PowerShell 5.1.26100 with `cmd /c exit 0`: ExitCode is $null and the
check throws; with the handle read right after Start-Process it is 0, and
`cmd /c exit 7` reads 7.
Read $oldDriver.Handle right after Start-Process so the object keeps the
handle and the exit code survives the exit.
Stable rehearsal rc.1-v0.23.2 failed the macos-packaged-arm64 arm the
same way on both attempts: v0.22.0 chatted, downloaded the update, quit
on Update now, then macOS showed "Hermes Agent quit unexpectedly" and
nothing relaunched within 15 minutes. The artifact could not say whether
OLD crashed on quit, NEW crashed at launch, or ShipIt never swapped,
because it held none of ShipIt's log, the crash reports or the installed
bundle's state.
When the update phase exits non-zero, the EXIT trap now runs
mac-update-evidence.sh into $LOG_DIR/update-evidence, which the job
already uploads:
- ShipIt's logs and a listing of its cache, plus any *updater* cache,
from both the sandbox HOME and the runner's real home, since Squirrel
and ReportCrash may not honour an overridden HOME. The staged update
is listed, never copied.
- Crash reports newer than a marker touched when the phase starts, from
both homes and /Library/Logs/DiagnosticReports.
- The installed bundle's identifiers, versions, install stamp,
app-update.yml, codesign display and verify, and spctl verdict.
- The app's Hermes logs, a Crashpad listing, matching processes, and the
unified log since the marker for ShipIt, the app, ReportCrash, and
syspolicyd/amfid lines naming Hermes.
It prints a summary into the job log. The collector only reads and copies.
It skips -u because macOS /bin/bash 3.2 treats an empty array as unbound.
The Windows and macOS packaged-update drivers launch the OLD app under
Playwright but kept nothing it printed. Its main process reports updater
failures there: on Windows the App Installer checker's stderr is logged
with console.error and goes nowhere else.
recordProcessOutput appends each stdout and stderr chunk to a file
synchronously, so the macOS driver's process.exit right after the app
closes cannot drop it. The macOS driver writes old-app-output.log beside
its other logs; drive-update.cjs writes app-output.log into the proof dir.
The driver logged only the Update now click, so its artifacts never showed
that it re-pressed the sidebar About for 300 s instead of Check now. It now
logs each navigation button it presses, once per change of target, since
the loop presses one every 3 s.
The windows-packaged arm has failed on every stable claim since it was
wired in (v0.22.1 claims; rehearsal rc.1-v0.23.2, x64 and arm64, both
attempts): after NEW is published, OLD shows "You're running the latest
version" and the local feed sees no request.
Find-InvokableButton walked buttons in UI Automation order and returned
the first that matched ANY pattern. On the About page the settings
sidebar's "About" entry comes before "Check now", so the navigation lookup
re-clicked About every 3 s and never re-checked. The only check of the
leg was OLD's startup check, made before NEW was published, which
correctly answered NO_UPDATES.
Reproduced on a Windows 11 26H2 VM with the real v0.22.0 and rc.1-v0.23.2
packages: the unmodified driver timed out with zero feed requests after
the publish; one real Check now click fetched the NEW descriptor and the
app offered Update now. The checker itself works in package context
(AVAILABLE).
Patterns are now tried in priority order, each against the whole tree,
and the navigation list puts '^Check now$' first. The lookup moves to
windows-uia-buttons.ps1 so it can be tested without the driver's
top-level run.
The post-chat signature check passes on the Nov 10 canary (re-run with this
branch's smoke: desktop-bundle-smoke run 43351151660): the chat's processes
start through bin/hermes, which redirects bytecode, and on macOS Desktop's
Python ticket helper only runs for a group-writable profile home. What does
write into the app is the backend's detached actions (gateway start, stop and
restart, update, skill and MCP installs): `_spawn_hermes_action` runs
`runtime_command`, `python -I -c <bootstrap>`, and -I ignores
PYTHONPYCACHEPREFIX.
The smoke now runs the cheapest command of that shape (`--version`) from the
installed payload and verifies the signature again. On a real Mac with the
Nov 10 app, extracted as the smoke extracts it, that command wrote 162 pycs
into the app (127 stdlib, 35 venv) and codesign reported "file modified"; on
the same payload baked by this branch it wrote nothing.
The macOS artifact smoke verified the app's signature only before launching
it, so an app that writes into its own bundle while it runs stays green. The
Nov 10 canary passed its smoke; on a real Mac the same build's ticket helper
rewrote 94 stdlib pycs inside the app, which codesign and spctl then
rejected. The smoke now runs `codesign --verify --deep --strict` again after
the chat.
The packaged-update e2e verifies the NEW bundle right after relaunch, which can
win the race against the app's first payload-Python spawn. It now verifies
the bundle again after the post-update chat.
Scripts outside the declaring workspace found these through the hoisted root node_modules:
mock-server and connector-rehearsal (whose desktop-local Electron path did not exist under npm),
ui-tui's visual harness, the eval harnesses, and the tests/install/e2e-assets drivers, which import
tests-js's @playwright/test and zod. They now resolve from apps/desktop or tests-js; the typed
e2e-assets files go through a tests-js re-export module so their types resolve the same way.
The packaged arm now always runs on Apple Silicon, but install-e2e still
forwards the arch a supplied manifest names. Reject anything but arm64 as the
job's first step, and make the driver require a host-native package so a
direct run cannot fall through to Rosetta either.
The published June Hermes-Setup.dmg updater writes the update marker with its
own PID and runs the v2026.7.30 checkout's `hermes update`, whose update lock
only recognises its orchestrator via HERMES_UPDATE_HANDOFF_PID (which the June
binary predates). The pre-pull CLI refuses with "Another Hermes update is
already running" and both desktop-installer@latest in-app legs from that tag
fail deterministically. The refusal runs in released code, so the update
target cannot fix it.
Extend the known-failures mechanism to macOS:
- rules carry `platforms` (default windows; existing rules unchanged)
- classifyWorkRoot reads the macOS harness layout (shas.env, home/.hermes)
- macos-desktop-e2e.sh rotates bootstrap-installer.log before the update,
collects HERMES_HOME/logs on failure, and only a full rule match (commit,
method pair, exact assertion, both fresh log signatures) yields a receipt
- install-e2e-macos-run.yml uploads the receipt as install-e2e-known-<id>--<leg>
- KNOWN_FAILURES.md documents the case with verified failing jobs
The Windows `installer-script+desktop -> hermes-desktop-app-update` leg from
v2026.7.30 failed every attempt with "desktop output is missing, stale, or
damaged: ...\release\win-unpacked.bak\...\dist". The old release's in-place
Windows pack (before-pack.mjs, #69179) kept the previous tree as
release\win-unpacked.bak; HEAD's update builds in a staging dir and swaps
release\win-unpacked via `.previous`, and by design never touches that `.bak`.
The product only ever launches the fixed appOutDir names, so the new app was
correct; verify_products globbed release/* and ran the freshness check on the
old rollback copy.
Restrict the verifier's output and executable discovery to electron-builder
appOutDir names, which never contain a dot (`.bak`, `.previous` copies do).
Every HEAD -> NEXT install/update E2E leg (Linux, macOS, Windows) failed with
"Running commit <HEAD> does not equal expected <NEXT>". The synthetic NEXT
commit adds only a marker file, so since 7a954418ce `hermes update` keeps the
packaged desktop app ("no desktop build input changed"), and that app keeps
naming the commit it was built from by design.
The smoke now accepts the app reporting NEXT's parent only when the installed
commit is a source checkout whose single change from that parent is the
synthetic marker file. Any real commit still requires the app to report it,
so a stale app after a real desktop change stays a failure.
- pm: AgentBrowser class + lock entry gone; Chromium default=True and its env
exports only PLAYWRIGHT_BROWSERS_PATH (Playwright launches without an
executable path still need it). A recorded or passed --without agent-browser
maps to chromium (pm.defaults.RETIRED_DEFAULTS), and pm gc forgets the stale
agent-browser fact so its store entry is reclaimed.
- install.sh --skip-browser/--no-playwright and install.ps1 -SkipBrowser pass
--without chromium; undo hint is hermes pm install chromium.
- Docker bakes /etc/hermes/chromium-executable-path; stage2-hook validates it
and exports nothing; the sandbox-desktop image drops the agent-browser npm
install and keeps its Playwright Chromium.
Every Windows x64 MSIX chat smoke since the Blacksmith migration (91fae5f8cb)
failed: first on the GitHub-hosted guard, and since that guard was removed
(272adc7b6f) with Playwright's "Process failed to launch!", on Electron 40 and
44 alike. The same builds' arm64 MSIX, on a GitHub-hosted runner, chats; the
last green x64 smoke (Oct 14) ran on windows-latest-32-core. Move the x64 leg
back there, as f1b290e773 did for the install/update GUI legs.
The failure itself carried no evidence: when the app exits before its debugger
line, Playwright's Electron.launch leaves sibling stderr-watcher rejections
unhandled, Node dies on them, and the smoke's catch never writes its receipt or
Playwright's call log. The driver now logs those rejections (still failing the
run), so the receipt records the app's exit code and stderr, and the Windows
smoke saves Application-log errors from the run on failure.
The parent stops waiting the moment the exit-code file exists, and Set-Content
creates it before the code is written, so a fast poll could read it empty.
Write to a .tmp sibling and rename it into place (atomic within a directory).
Greptile review on #142322.
Builds on #142306 (Maciej, @c2h5oh). That PR taught the desktop smoke that the
listener Desktop dials can be the canonical gateway named in the home's
gateway_state.json, and proves that gateway's tree by the cwd `gateway ensure`
starts it in. Install-e2e run 39567335733 (main + this branch) hit two cases it
does not reach:
- Windows: CIM exposes neither the cwd nor the environment of another process.
Every desktop checkpoint that reached the (now startable) detached gateway
failed with "Source backend listener imports a different source tree
(cwd=(unreadable), HERMES_PYTHON_SRC_ROOT=(unset) ...)". The gateway now
vouches for itself there. localBackendProcess keeps the code_sha the gateway
stamped into its own gateway_state.json (gateway/status.py). assertBackendOrigin
accepts the app's reported root for it only when that code_sha is the
installed commit, which both callers already read. A readable cwd is still
the evidence everywhere else, and the child/ledger rules are unchanged.
- All OSes, HEAD -> NEXT app-driven update legs: update-window-chat.mjs called
localBackendProcess without a home, so it never looked for the canonical
gateway ("Expected one Desktop-owned, registered host or canonical gateway
backend listener on port N; found 0"). It now passes the app's own
hermesHome and the installed commit.
On GitHub-hosted Windows runners every step process sits in a job object whose
limits lack JOB_OBJECT_LIMIT_BREAKAWAY_OK (flags 0x0), and Hermes deliberately
refuses to start a gateway it cannot detach
(gateway_runtime_start.py::spawn_unmanaged_gateway uses CREATE_BREAKAWAY_FROM_JOB;
OSError -> windows_breakaway_unavailable). Legs that update from old releases
(v2026.7.1 / v2026.9.24 -> HEAD) have no usable Hermes_Gateway Scheduled Task, so
the desktop app's `gateway ensure` must spawn directly, gets PermissionError
winerror 5, and the app shows "Gateway inaccessible" with the composer covered.
Reinstall legs pass only because the installer's task starts the gateway.
A user's Explorer/Start-menu launch is in no job. Probing the real interpreter on
a hosted runner (proof run 39560661908): the step and a Scheduled Task's process
are both in a 0x0 job and breakaway fails; a Win32_Process.Create child and an
explorer.exe child are in no job and breakaway succeeds. Invoke-OutsideRunnerJob
launches each desktop checkpoint as a WMI child, replaying this step's
environment, cwd and arguments from a spec file, and returns its exit code. The
journey mock stays in the step; the app reaches it over localhost.
The Linux driver already starts one mock before its first desktop checkpoint
(installer-script-e2e.sh, same "The mock must receive this checkpoint prompt
after the send" history). The macOS desktop and Windows drivers did not: their
install-phase checkpoint ran before any journey mock existed, so the smoke
started a private one, and the detached gateway that checkpoint left running
kept that private URL. The update step's mock then had no prior URL to rebind
(run 39529658809: gateway on :58214, the smoke's private mock; new journey mock
on :52889, empty chat-mock-error.log).
macos-desktop-e2e.sh now runs mock_start before the install checkpoint, and
windows-e2e.ps1's Invoke-DesktopCheckpoint starts the journey mock first
(idempotent per step), so the whole journey keeps one URL and later steps
rebind its port.
An install/update journey runs its phases in separate CI steps. Each step's
mock provider dies with its step, but the gateway Desktop started is detached
on purpose and survives into the next step with the provider URL it read at
boot. The next step started a mock on a fresh port and rewrote config.yaml/.env,
so the surviving gateway kept dialing the dead port: every HEAD -> NEXT desktop
leg on macOS and Windows failed with "The mock must receive this checkpoint
prompt after the send" (run 39523017025: agent.log shows the gateway calling
127.0.0.1:61022 while the new mock listened on 53982; macOS 49478 vs 49533).
Linux passed only because its mock happened to survive between steps.
mock-provider.mjs now takes the prior step's URL and rebinds that port when it
is free (any free port otherwise), and both callers (mock_start and
Start-DesktopJourneyMock) pass it. The config stays byte-identical across
steps, and the chat smoke's commit check still proves the gateway runs the
updated code.
Since #106742 Desktop reaches its local backend through `hermes gateway ensure`,
which attaches to (or starts, detached) the canonical `gateway run` daemon. That
listener is reparented away from Electron and has no `serve` spawn-ledger record,
so localBackendProcess found 0 listeners and every Linux +desktop install/update
leg failed after an otherwise healthy boot.
Accept a third listener kind, `host-gateway`: the pid gateway_state.json names in
the home under test or its machine root, running, kind hermes-gateway, same
incarnation (start_time in gateway.status units), and the actual OS listener on
the connected port. The installed-tree origin check is unchanged and gets no
app-report waiver for it; the gateway proves its tree by the install-root cwd
`gateway ensure` starts it in.
`hermes update` has followed the stable channel for official source checkouts
since #135847, but install.sh and install.ps1 still cloned main's tip, so every
new user (CLI one-liners and Hermes-Setup, which bakes `-Branch main`) started
on unreleased code and only reached stable at the next release.
For the official repository's main line, with no explicit --commit:
- a fresh install resolves the latest published vX.Y.Z release (GitHub API,
then the github.com /releases/latest redirect, which needs no API quota),
fetches its tag (releases can sit on release/* branches) and checks it out
detached, where `hermes update` puts a stable checkout;
- a rerun with no recorded channel moves forward to that release and keeps a
checkout that already contains it (forward-only, like the update default);
if the lookup fails a rerun keeps its checkout instead of jumping to main;
- `--channel main` / `-Channel main` / HERMES_INSTALL_CHANNEL=main installs
main's tip and saves the choice with `hermes update --set-channel`, so later
updates keep following main. Forks, mirrors and other branches are unchanged.
The install E2E harnesses that serve unreleased commits from a tagged local
mirror pin themselves to main through the same variable.
48 commits from main (e8c8e46471). One conflict: hermes_cli/runtime_provider_custom.py, where both sides
added the `config=` keyword to _get_named_custom_provider; main's signature (config + resolve_credentials)
is taken whole.
bundle-inputs.mjs downloaded the ~100 MB package with one fetch. The CDN
reset the connection mid-body (`TypeError: terminated`, ECONNRESET) and the
Windows arm64 acceptance leg of Stable release rc.1-v0.22.1 died on a
network blip. A reset or timeout now retries the whole download up to 3
times; an HTTP error or a wrong digest is a real defect and still fails
at once. The manifest fetch gets the same treatment.
375 commits from main (0e427d788d). 24 files conflicted; the resolutions that carry a decision:
- /initiate-setup: main removed the command (25bf722063). Its gateway rewrite, CLI handler and the
Desktop kickoff go with main; this branch's command-layer admission of it is dropped too
(gateway/session_commands.py _PROMPT_COMMANDS, its slash.exec test row, the parity doc row), and
the Desktop slash dispatcher loses the `hidden` option that only the kickoff used.
- Code this branch moved out of its old file, carrying main's edits to the moved copy:
first-contact notes (gateway/run_turn.py -> run_turn_prepare.py: no message/setup_command),
the TUI agent factory (tui_gateway/server.py -> agent_factory.py: onboarding toolsets at build,
setup_beat/set_theme lifecycle cards, no cli platform extras on a coding selection), the serve
lifespan (web_server.py -> web_server_app.py standalone_lifespan: first-install probe before the
state.db reconcile, onboarding due answer after the setup bootstrap), and the compression child
publish (the shared _publish_compression_child_on_conn reads the parent's model_config).
- agent/auxiliary_client.py: both import changes (_route_key from main; this branch's move of
_without_structured_output_format).
- Desktop: main's onboarding run (decideOnboarding, OnboardingEnd, card-waiting Send) replaces the
kickoff; this branch's prepared-submission slash path, request_id on session.create and
PreparedImageRecovery stay. Pool-limits imports are dropped (this branch removed the pool).
createBackendSessionForSend takes main's (preview, overrides) signature.
- ci.yaml detect job: main's `ref: inputs.commit` plus this branch's sparse checkout.
- package.json / lock: main's vitest 4.1.11 plus this branch's ws 8.21.1.
- Generated: gateway-contract.openrpc.json regenerated; parity doc regenerated.
App Installer downloads MSIX packages through Delivery Optimization,
which refuses a server without HTTP Range support: the v0.22.0 rc.2
Windows signed-package acceptance failed its first ever run with
Add-AppxPackage 0x80D05011 (DO_E_INSUFFICIENT_RANGE_SUPPORT) opening
old.msixbundle from the local feed. The feed now advertises
Accept-Ranges, answers single ranges with 206 and Content-Range, 416
for an unsatisfiable range, and HEAD with headers only.
Review found that a run on main still treated main's tip as the commit
under test in several places, and shared concurrency groups with pushes.
- Concurrency: 14 nested workflows keyed their group on the ref, or on
"tag". A stable run is on main, so a push could cancel its checks. They
now use the run id when the caller passes a commit, and never cancel.
- Docker and Nix archived, stamped and labelled GITHUB_SHA. They now use
CANDIDATE_COMMIT, which is the commit input or the triggering commit.
- Install e2e compared the package manifest with GITHUB_SHA. It now reads
HERMES_TESTED_COMMIT.
- e2e-desktop rewrote the visual baselines whenever the ref was main. A
stable run now only compares.
- The lint test checks the value each nested call passes, every
concurrency group, and any other use of the triggering ref or SHA.
Since #137522 and #137807 a fresh desktop install opens the first-run
onboarding chat. The install/update E2E desktop chat smoke then sent its
checkpoint prompt into that chat instead of a normal one, so the mock
never received it ("The mock must receive this checkpoint prompt after
the send"), and on the Windows GUI installer path the installer-launched
app was mid onboarding turn when the journey closed it, so it did not exit
within 30 s. Seen on v0.22.0 attempt rc.1 in three Windows
desktop-installer@latest (HEAD -> NEXT) legs.
The mock provider writer now sets onboarding.run: false in the root
config, and the Windows GUI install phase seeds the same key before the
installer launches the app. The journeys test install and update, not
onboarding (which has its own desktop e2e spec).
No conflicts. Brings in main's fixes for the reds release run 38120936161 inherited:
79b45d1647 (signed reasoning replays after resume on Anthropic/Bedrock Converse),
7831de8999 + d3bdf761b0 (network upgrade E2E follow the new main-channel default),
0aa764fedd (Desktop hand-off test expects no channel-record request on main).
rc.10-v0.21.7 failed 13 release jobs because the release-only E2E still
assumed the old update behavior:
- Install/update E2E (Linux, macOS, Windows; hermes-update and desktop-app
routes). A fresh install of the official repo now defaults to the stable
channel. Installed at HEAD it is newer than v0.21.6 and correctly waits
("Already up to date"), so the HEAD -> NEXT legs never moved ("checkout
landed on NEXT", "no successful update completion receipt"). The drivers
now record `hermes update --set-channel main` before the user-state
snapshot, the same way the pytest sandboxes already do (3a4b4b6f83).
Releases older than --set-channel follow main already and are skipped by a
help probe.
- Network E2E (test_offline_and_flaky, test_proxy_only_egress). They asserted
that `main` reads and retries releases/channels/main.json through the
proxy. #136429 removed that read on purpose (regional WAF 403s, #128295).
Rewritten to the new contract: `main` reads no release record, survives a
release-host outage, and a cut tunnel to github.com still fails fast and
changes nothing.
The desktop unit test with the same assumption was already fixed on main
(0aa764fedd).
Conflicts: tests/hermes_cli/test_finite_chat_delegation.py and
tests/tools/test_completed_process_results.py, where main's lint sweep (0006a5e229) added
check=False to subprocess.run calls this branch had rewritten. Kept the branch's test bodies
and carried check=False onto their subprocess.run calls.
17 conflicts, all from main's lint sweep (ruff UP007/UP017/UP022/UP028/UP031/UP037/UP041,
FURB188/FURB192); no other main commit touches a conflicted file. Resolution: the branch side
of each file plus main's exact autofix (ruff 0.15.10, main's ruff.strict.toml, --fix
--unsafe-fixes). ruff.strict.toml takes main's copy. The pool-retirement live fixture stays
deleted with the pooled backend this branch retires.