The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(desktop): verify updated runtime before success receipt
Teknium90ac288c7d18
diff --git a/scripts/desktop-update/windows.ps1 b/scripts/desktop-update/windows.ps1index 6c9bcc01675..2fdc441338a 100644--- a/scripts/desktop-update/windows.ps1+++ b/scripts/desktop-update/windows.ps1@@ -1595,6 +1595,17 @@ try {if ($rebuild.Code -ne 0) { $desktopBuildFailed = $true }}+ # A zero-exit update is not proof that the runtime survived the update.+ if ($res.Code -eq 0 -and -not $desktopBuildFailed) {+ $verify = Invoke-HermesStep $pythonExe @("-c", "import hermes_cli.main") "verify"+ if ($verify.Code -ne 0) {+ $finalCode = 8+ $finalMsg = "The updated Hermes runtime failed verification. Repair the installation and review antivirus quarantine before retrying."+ Write-HandoffLog $finalMsg+ exit $finalCode+ }+ }+if ($res.Code -eq 0 -and -not $desktopBuildFailed) {$finalCode = 0$finalMsg = "Update complete."diff --git a/website/docs/getting-started/updating.md b/website/docs/getting-started/updating.mdindex 3076a128a12..7b84c2a7cf7 100644--- a/website/docs/getting-started/updating.md+++ b/website/docs/getting-started/updating.md@@ -34,7 +34,7 @@ When you run `hermes update`, the following steps occur:### Missing Windows updater files-If the maintained updater script is missing (for example after antivirus quarantine), the legacy update forwarder fails instead of reporting a successful hand-off. Repair the installation and review the security software's quarantine report before retrying; do not disable antivirus protection. This prerequisite check does not verify a completed desktop build.+If the maintained updater script is missing (for example after antivirus quarantine), the legacy update forwarder fails instead of reporting a successful hand-off. Repair the installation and review the security software's quarantine report before retrying; do not disable antivirus protection. The maintained updater also checks that the updated Python runtime can import the CLI before reporting success. These checks do not validate the desktop artifact's build stamp.### Updating against a non-default branch: `--branch`