Skip to content

fix(update-check): surface failed preamble checks#1982

Draft
maxpetrusenkoagent wants to merge 1 commit into
garrytan:mainfrom
maxpetrusenkoagent:hermes/oss-pr-2026-06-12-gstack-1974
Draft

fix(update-check): surface failed preamble checks#1982
maxpetrusenkoagent wants to merge 1 commit into
garrytan:mainfrom
maxpetrusenkoagent:hermes/oss-pr-2026-06-12-gstack-1974

Conversation

@maxpetrusenkoagent

Copy link
Copy Markdown

Summary

  • Add a CHECK_FAILED exit=<n> cmd=<cmd> stdout sentinel for abnormal gstack-update-check failures.
  • Preserve existing quiet behavior for up-to-date, snoozed, disabled, and network-unavailable checks.
  • Keep telemetry fire-and-forget paths from triggering false CHECK_FAILED output.

Fixes #1974.

Root cause

Skill preambles invoke gstack-update-check with stderr suppressed and || true, so a local script crash was indistinguishable from an up-to-date/no-output result. With set -euo pipefail, state-file write/remove failures could terminate before the remote version was checked.

Verification

  • bash -n bin/gstack-update-check
  • bun test browse/test/gstack-update-check.test.ts test/skill-validation.test.ts → 369 pass, 0 fail on fork-base branch after cherry-picking the fix
  • git diff --check
  • bun run gen:skill-docs --dry-run --host claude → fresh
  • bun run gen:skill-docs --dry-run --host codex → fresh
  • bun run skill:check was attempted; it fails on pre-existing missing/stale optional host outputs (.factory, .kiro, .opencode, .slate, .cursor, .openclaw, .hermes, .gbrain). Claude and Codex generated outputs are fresh.

Autoreview

  • Claude subagent review: no blocking findings. One non-blocking test determinism caveat noted for privileged/root runners.
  • Codex review pass 1: requested exact preamble-wrapper coverage.
  • Added exact two-leg generated preamble wrapper regression test.
  • Codex final review: CLEAN: no findings.

Fork note

The branch is based on the current maxpetrusenkoagent/gstack:main fork tip because the fork cannot be server-synced past upstream workflow-file commits without GitHub workflow OAuth scope. The PR diff against garrytan/gstack:main contains only this focused fix.

@trunk-io

trunk-io Bot commented Jun 12, 2026

Copy link
Copy Markdown

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here

@maxpetrusenkoagent maxpetrusenkoagent force-pushed the hermes/oss-pr-2026-06-12-gstack-1974 branch from 788027c to d747803 Compare June 12, 2026 00:39
@maxpetrusenkoagent

Copy link
Copy Markdown
Author

Autoreview after latest force-push: Codex reviewed the exact GitHub PR diff for #1982 and returned CLEAN: no findings. Local verification on the pushed branch: bash -n bin/gstack-update-check, bun test browse/test/gstack-update-check.test.ts test/skill-validation.test.ts (369 pass, 0 fail), and git diff --check. Note: GitHub currently reports no checks for this fork draft PR.

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.

update-check crash is indistinguishable from "up to date" — preamble invocation fails open

1 participant