Skip to content

[codex] Rebuild desktop package when install stamp drifts - #82

Merged
OmarB97 merged 1 commit into
mainfrom
fix/desktop-update-stale-package-stamp
Jun 4, 2026
Merged

[codex] Rebuild desktop package when install stamp drifts#82
OmarB97 merged 1 commit into
mainfrom
fix/desktop-update-stale-package-stamp

Conversation

@OmarB97

@OmarB97 OmarB97 commented Jun 4, 2026

Copy link
Copy Markdown
Owner

Summary

  • Fixes the Update Now flow where Hermes relaunches successfully but keeps reinstalling an old packaged desktop app.
  • Makes hermes desktop --build-only compare the packaged app embedded install-stamp.json identity with the current checkout identity before trusting the content-hash cache.
  • Adds focused GUI command tests for matching and stale packaged install identities.

Root Cause

The updater handed off correctly and ran hermes update, but the rebuild step could say Desktop packaged app is up to date (content stamp matches) when desktop source content was unchanged. That allowed it to reinstall the existing apps/desktop/release/mac-arm64/Hermes.app, whose embedded stamp and app.asar still came from the old branch/ref.

Verification

  • uv run pytest tests/hermes_cli/test_gui_command.py -q
  • npm run test:desktop:platforms --workspace apps/desktop
  • python3 -m py_compile hermes_cli/main.py
  • git diff --check origin/main..HEAD

Upstream

Upstream counterpart is included in NousResearch#39192.

@OmarB97
OmarB97 marked this pull request as ready for review June 4, 2026 16:45
@OmarB97
OmarB97 merged commit beb4a96 into main Jun 4, 2026
20 of 22 checks passed
@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

🔎 Lint report: fix/desktop-update-stale-package-stamp vs origin/main

ruff

Total: 0 on HEAD, 0 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 0 pre-existing issues carried over.

ty (type checker)

Total: 9844 on HEAD, 9842 on base (🆕 +2)

🆕 New issues (2):

Rule Count
invalid-assignment 1
invalid-argument-type 1
First entries
hermes_cli/main.py:7304: [invalid-assignment] invalid-assignment: Invalid subscript assignment with key of type `Literal["installIdentity"]` and value of type `dict[str, str | None] & ~AlwaysFalsy` on object of type `dict[str, str | bool]`
tests/hermes_cli/test_gui_command.py:390: [invalid-argument-type] invalid-argument-type: Argument to function `_write_packaged_install_stamp` is incorrect: Expected `dict[str, object]`, found `dict[str, str]`

✅ Fixed issues: none

Unchanged: 5105 pre-existing issues carried over.

Diagnostics are surfaced as warnings — this check never fails the build.

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