- A tree a refused enable left behind is retried only when this home's
own automatic attempt left it (per-home, per-plugin failure stamp);
a tree the user installed by hand, or one they enabled/disabled since,
stays theirs. Regression test from @BearHuddleston's review patch.
- An owed boot step whose retry raises stays owed (kshitijk4poor).
- An offline pass (live catalog unreadable) still installs the in-tree
defaults but stays owed, so a default added to the live catalog after
this release lands on a later boot (kshitijk4poor).
- default_entries rechecks the tier (the live/in-tree merge can carry
default onto a community entry) and reuses the install gate's own
platform/version verdict instead of a copy of it.
- A failed pass clears the settled marker, so a later failure (a
profile created after the revision settled) is retried too.
- Docstring: one failure stamp, not per plugin.
Co-authored-by: BearHuddleston <bear@bearhuddleston.dev>
A catalog entry at tier official or verified can now set `default: true`.
Every Hermes home then gets it installed at its catalog pin and enabled,
once:
- at the end of every source install and `hermes update` (the shared
maintenance tail install.sh / install.ps1 / the updater all run), for
every profile home;
- on first start, through the boot bootstrap, for installs that never run
that tail (bundled Desktop payload, Docker, Nix, Termux); a failed fetch
stays owed and is retried on later starts behind an hour-to-a-week
backoff checked before any network;
- when a profile is created.
Each home records what it got in `_default_plugins_installed` (the way the
left-core migrator records its one-time install), so a user who removes or
disables a default plugin keeps that choice through later updates. Homes
with security.allow_lazy_installs off fetch nothing. The parser ignores
`default` on community entries and the catalog validator refuses it.
Lane B1.12 (default plugins installed and enabled from the catalog).
Final-head review wave on 4fa5119686:
- The web console's `config migrate` raised "stopped at v21" without the cause:
the console drops a failing command's printed output, so the warning never
reached the user. The error now carries the step's warning
("config migration to v21 failed: unhashable type: 'list' ...").
- A boot retry that raised (a full disk while taking the backup) kept the
earlier step's `failed_warning`, so doctor showed the old reason. It now
records this retry's error; the step stays owed.
- `drop_legacy_disabled_for_key` (tools/) returns whether it dropped the key
and `set_config_value` prints the note, like the `legacy_key` note next to it.
Round 2 on #152494 (review wave on b6c1e0d5 / a080bcbe41):
- Plain `hermes doctor` showed the boot record's summary ("kept v20->v20,
retried on the next start") instead of the cause. `step_migrate_config` now
stores `failed_warning` in its result and doctor shows it ("unhashable type:
'list'"), so the body's "doctor says why the version is behind" holds
without `--fix`.
- `hermes config migrate` printed "✓ Configuration updated!" and exited 0 on a
pass that stopped (the same false success kvnloo found on `hermes update`).
It now prints the warning, no success line, and exits 1. The console's
`config migrate` raises a command error instead of "Configuration updated".
- A start that owes a step ran the install identity lookup (a `git rev-parse`
plus a pm lookup, ~55-110 ms) twice. `run_boot_bootstrap` computes it once
and hands it, with the record it already read, to `_retry_owed_migration`.
Probe: 2 lookups per owed start before, 1 after.
- Boot and doctor read the owed migration through one public
`boot_bootstrap.owed_config_migration`, instead of each walking the
record's dict layout.
- `PUT /api/config/raw` uses the shared `http_failure` mapper like
`PUT /api/config`, so an unexpected failure is logged and answered with
the same opaque 500.
- The at-most-one-write ratchet now also fails when a step is not triggered by
its shared document, unless that step is listed with its reason (5 are:
v13 and v41 write no config.yaml; v21, v31 and v40 need a value another
step's trigger contradicts).
Boot retries a config migration that stopped at a failing step on every
start while the record holds failed_step. A retry that raised before the
ladder ran (a full disk while taking the backup) recorded ok False with
no failed_step, so the obligation was dropped until the next revision.
Keep the previous failed_step unless the retry returns ok.
run_migrations also records the failing step's warning in
results["failed_warning"], so boot and doctor no longer search the
warning list for it (that lookup raised StopIteration on a miss).
A step that raised was logged and skipped, then migrate_config stamped the
latest version, so the step never ran again (v21 on a nested list in
plugins.disabled: plugins stayed off for good). Boot could not keep partial
progress either: any stamp below latest counted as a failed migration and
restored the backups.
- run_migrations stops at the first failing step and returns it; the
stamp moves only to the step before it. Later steps wait, so a one-time
step never runs twice over a value the user set in between. An
unversioned file that fails stays unversioned.
- Boot keeps the steps that succeeded, records the failing step, and
retries it on every start of the same revision (one warning per start,
also kept for the next visible turn). Docker does the same.
- hermes doctor says why the version is behind, and --fix reports a pass
that stopped instead of "migrated".
- A config stamped by a newer build runs no step, keeps unknown keys, and
refuses whole-file saves; key-level writes (config set) still save.
- The remote backend migrates in memory and never writes back, so it
keeps running the whole ladder.
- disable_suspicious_mcp_servers moves to config_migrations (size cap).
On Windows, subprocess text=True without an explicit encoding decodes
child output with the ANSI code page (e.g. 'gbk'); non-ASCII bytes then
raise UnicodeDecodeError inside subprocess._readerthread, killing the
Hermes backend before it becomes ready and surfacing as the desktop boot
timeout.
Sweep every hermes_cli text=True subprocess call to encoding='utf-8',
errors='replace', and add an AST-based regression test that fails when a
future text-mode call omits the encoding.
Fixes#55658
post_update._install_root, boot_bootstrap.default_project_root,
update_channel._default_root, version_info._CODE_ROOT + _resolve_stamp_file,
_launchers.publish_launchers and pm.runtime each re-derived "HERMES_INSTALL_ROOT
or the code root". pm.paths.install_root() is the one place now; pm.store reuses
the downloader's User-Agent instead of carrying a second one.
hermes_cli.runtime_paths (venv generations, selection, activation) moves to
pm.environments, and gains venv_bin_dir / venv_python / project_python. Every
in-tree caller asks pm for an interpreter now; pm no longer reaches back into
hermes_cli for its own environment layout (pm.packages, pm.extras, pm.ensure,
pm.paths imported hermes_cli.runtime_paths). The three open-coded
"Scripts/python.exe or bin/python" ladders in pm collapse onto venv_python.
hermes_constants.venv_python_path / venv_bin_dir and hermes_cli.runtime_paths
stay as frozen-updater-surface shims only (tests/compat/old_updater_surface.json).
To keep the boot path light, pm/__init__ resolves its facade lazily (PEP 562)
and pm.registry loads the built-in package definitions on first read instead of
at import: `import hermes_bootstrap` now loads pm + pm.environments only (25ms,
was 37ms with the eager facade dragging in the downloader). The stripped-payload
fixtures that ship only pre-import files keep working for the same reason.
Also restores two frozen-surface re-exports the F401 sweep dropped
(banner._github_compare_behind, cua_backend.resolve_cua_driver_cmd).
Competing installers and checkout-local venv assumptions bypassed PM
selection, install consent, and generation lifetimes. Route consumers
through PM and installation-bound launchers. Refresh source launchers
before obsolete Python entries can be collected.
Remove Node, browser, and CUA acquisition engines, obsolete venv-holder
handling, detached sync, and unused PM APIs. Keep historical updater
exports inert and preserve external tool ownership and native integration.
Share product freshness and prepared inputs across builders. Align plugin
admission, Docker provisioning, setup instructions, and behavioral tests.
Verified targeted Python and JavaScript tests, desktop and web typechecks,
scoped lint, real product builds, and the Docker frontend smoke test.
The missed post-setup test cleanup is included and verified.
Native Windows/macOS execution, full Rust compilation, and the complete
repository suite remain unverified. Historical compatibility requirements
were preserved and extended, not fully rescanned.
Prepare dependency generations before selecting them. Keep shipped tool
bytes separate from writable additions, and store facts beside their entries.
Validate proposed plugin sets before config publication. Restore the previous
config if the facts write fails.
Consolidate duplicate updater, backup, setup, and voice helpers. Repair
launcher selection, dependency consumers, download ownership, update feeds,
and native Windows process and file handling.
Verification: 206 changed/prior-failing Python files reported 4630 passed,
one failed, and 330 skipped. Fix the remaining Hindsight fixture boundary.
The final targeted rerun reported 234 passed and two skipped. The store
review regression batch reported 83 passed and one skipped. Desktop
TypeScript checks, 56 selected Electron tests, 24 release tests, and the
removed-import/compatibility guards passed.
This is an integration checkpoint, not full audit acceptance. The complete
Python suite has not run on this fixed tree. Crash-atomic plugin publication,
generation cleanup, receipt correlation, and packaged lifecycle acceptance
remain open in docs/pm-audit-status.md.
Wire the desktop app onto the pm store for real distribution:
- MSIX bundle: electron-builder config, appx assets, manifest, copilot
key + deep-link routing, App Installer + Windows Store variant
(sign only the msix; inner binaries covered by the package block map)
- Rust CLI shim (apps/desktop/shim) — bundled builds run from the store
python + shim, never the venv; payload symlinks relativized so the
relocatable venv survives relocation
- Cloudflare R2 release pipeline: publish binaries + update feeds,
nightly channels/tags, stamp-first version resolution
- Update system: gate, uninstall steward, boot bootstrap, release
channels, update receipts
- install.ps1 reduced to a 361-line stage-protocol bootstrapper (heavy
deps are pm's job); darwin updater + update-channel mirror ripped
- doctor: main's re-landed TCC anchor kept, termux branches removed
Rebuilt from ethie/pm onto the pm-store stack. 22 hot files hand-merged;
uv.lock + package-lock.json keep main's newer dep tree; test_engines
reads the pm/lock.json pin; lazy_deps.py deleted (all 222 importers
migrated to pm in the foundation commit).