Skip to content

fix(test): avoid macOS release gate deadlocks - #116972

Merged
vincentkoc merged 2 commits into
mainfrom
fix-sticky-disk-node-stdin-20260731
Jul 31, 2026
Merged

vincentkoc merged 2 commits into
mainfrom
fix-sticky-disk-node-stdin-20260731

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Jul 31, 2026 •

Copy link
Copy Markdown
Member

Summary

  • execute workflow run: fixtures from temporary script files instead of bash -c
  • materialize inline Node module heredocs as temporary .mjs files at the simulated checkout root
  • use macOS system Bash for release-evidence resolver fixtures instead of Homebrew Bash 5.3
  • remove two independent macOS deadlocks that blocked the repo-native full test gate

Root causes

  1. test/scripts/ci-workflow-guards.test.ts replayed GitHub Actions run: blocks containing Node heredocs through synchronous bash -c. On macOS this could deadlock inside Vitest. The harness now mirrors GitHub Actions by writing script files and materializing inline modules.
  2. test/scripts/find-reusable-release-validation.test.ts intermittently deadlocked in nested command substitutions when Homebrew Bash 5.3 was launched through Node's synchronous child runner. GitHub Actions uses system Bash, so the macOS fixture now selects /bin/bash.

Validation

  • combined focused run: 130 passed, 1 skipped
  • release reuse fixture: unfixed repeated loop hung on run 3
  • release reuse fixture: fixed loop passed 10 consecutive runs (38 tests each)
  • ./node_modules/.bin/oxfmt --check test/scripts/ci-workflow-guards.test.ts test/scripts/find-reusable-release-validation.test.ts
  • git diff --check

No changelog entry: test harness reliability only.

@vincentkoc vincentkoc self-assigned this Jul 31, 2026
@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Jul 31, 2026
@vincentkoc
vincentkoc marked this pull request as ready for review July 31, 2026 17:47
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. labels Jul 31, 2026
@clawsweeper

clawsweeper Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 3:10 PM ET / 19:10 UTC.

ClawSweeper review

What this changes

The branch changes two release-gate test fixtures to run workflow heredocs from temporary files and to select macOS system Bash for the release-evidence resolver.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

This PR remains necessary: current main still executes the CI-manifest fixture through synchronous bash -c and the release-reuse fixture through PATH-selected Bash, matching the two reported macOS deadlock boundaries. The supplied focused-loop evidence and patch shape are credible, but this member-authored, maintainer-labeled PR must remain in the normal exact-head maintainer-review lane while its CI is still running.

Priority: P3
Reviewed head: 5d38e176b294ff2343066dd6406240a12d2bd8df

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The repair is narrowly aligned with current fixture behavior and has reported focused stress evidence, with exact-head CI still needed before merge.
Proof confidence 🌊 off-meta tidepool Not applicable: This member-authored, test-only PR supplies focused macOS loop results in its body; exact-head CI is the remaining appropriate confirmation rather than an external contributor proof gate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This member-authored, test-only PR supplies focused macOS loop results in its body; exact-head CI is the remaining appropriate confirmation rather than an external contributor proof gate.
Evidence reviewed 5 items Current CI fixture boundary: Current main runs the selected workflow manifest command through bash -c, so the proposed temporary-script execution targets the actual fixture boundary described by the PR.
Workflow module contract: The guarded CI step is a Node ESM heredoc whose relative imports resolve from the checkout; the proposed fixture materializes the module at its simulated checkout root while retaining that working directory.
Current resolver shell selection: The current resolver fixture launches bare bash; the PR's macOS-only /bin/bash selection directly replaces that invocation and leaves non-macOS behavior unchanged.
Findings None None.
Security None None.

How this fits together

The CI workflow-guard test simulates a GitHub Actions run: block to verify the generated CI manifest, while the release-validation test invokes the release-evidence resolver against local GitHub fixtures. Both feed the repository’s release-gate confidence rather than product runtime behavior.

flowchart LR
  A[CI workflow definition] --> B[Workflow-guard fixture]
  B --> C[Temporary shell and module files]
  C --> D[Node manifest generation]
  E[Release-evidence fixtures] --> F[Resolver shell script]
  F --> G[Reuse decision assertions]
  D --> H[Release-gate test confidence]
  G --> H
Loading

Before merge

  • Resolve merge risk (P1) - Exact-head CI is still in progress, so the reported macOS stress-loop result has not yet been independently corroborated on the latest force-pushed head.
  • Resolve merge risk (P1) - The local blobless partial clone could not retrieve the two PR blobs or the prior reviewed SHA after DNS failure; maintainers should rely on the current PR patch and exact-head CI for final line-level confirmation.
Agent review details

Security

None.

PR surface

Tests +40. Total +40 across 2 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 2 47 7 +40
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 2 47 7 +40

Review metrics

None.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Land the focused fixture repair only after exact-head CI confirms the two test files still pass, preserving the checkout-root module location and macOS system-Bash selection documented by the PR.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Land the focused fixture repair only after exact-head CI confirms the two test files still pass, preserving the checkout-root module location and macOS system-Bash selection documented by the PR.

Do we have a high-confidence way to reproduce the issue?

Unclear: the PR gives a concrete repeated macOS fixture-loop path and reports a pre-fix hang followed by ten passing fixed runs, but this read-only environment could not independently execute or fetch the latest PR blobs.

Is this the best way to solve the issue?

Yes, conditionally: executing the workflow body from a file better mirrors GitHub Actions than bash -c, and placing the generated ESM module at the simulated checkout root preserves the relative-import contract used by the guarded workflow.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against eb0087dc7c96.

Labels

Label justifications:

  • P3: This is a focused test-harness reliability repair with no direct runtime, data, authentication, or message-delivery behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This member-authored, test-only PR supplies focused macOS loop results in its body; exact-head CI is the remaining appropriate confirmation rather than an external contributor proof gate.

Evidence

What I checked:

  • Current CI fixture boundary: Current main runs the selected workflow manifest command through bash -c, so the proposed temporary-script execution targets the actual fixture boundary described by the PR. (test/scripts/ci-workflow-guards.test.ts:67, eb0087dc7c96)
  • Workflow module contract: The guarded CI step is a Node ESM heredoc whose relative imports resolve from the checkout; the proposed fixture materializes the module at its simulated checkout root while retaining that working directory. (.github/workflows/ci.yml:387, eb0087dc7c96)
  • Current resolver shell selection: The current resolver fixture launches bare bash; the PR's macOS-only /bin/bash selection directly replaces that invocation and leaves non-macOS behavior unchanged. (test/scripts/find-reusable-release-validation.test.ts:474, eb0087dc7c96)
  • Feature-history provenance: Blame attributes both current fixture boundaries to the same current-main CI/test addition, so the PR is repairing a coherent test-harness neighborhood rather than unrelated code. (test/scripts/ci-workflow-guards.test.ts:77, c2e5b3a67c3f)
  • Latest-head scope: The PR tree changes only the two intended test fixtures. Local retrieval of the promised blob contents and prior-review SHA failed because this checkout is a blobless partial clone and DNS could not reach its promisor remote; the provided PR patch and body were used for the exact-head review. (test/scripts/ci-workflow-guards.test.ts:1, 5d38e176b294)

Likely related people:

  • vincentkoc: Current-main blame attributes both affected fixture boundaries to Vincent Koc's CI test expansion, and the PR commits continue that same area. (role: current fixture author and recent CI/test contributor; confidence: high; commits: c2e5b3a67c3f, ec0c41f1e280, 5d38e176b294; files: test/scripts/ci-workflow-guards.test.ts, test/scripts/find-reusable-release-validation.test.ts)
  • Peter Steinberger: History shows repeated work on the workflow-guard fixture and release-validation fixture, including recent CI and release-test changes. (role: historical CI-test contributor; confidence: medium; commits: a2f845e6c84f, ac95af2c417b; files: test/scripts/ci-workflow-guards.test.ts, test/scripts/find-reusable-release-validation.test.ts)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Let the currently running exact-head CI finish, with particular attention to the two focused test fixtures and any macOS-backed lane.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-07-31T17:53:16.872Z sha 3f6ba3d :: needs maintainer review before merge. :: none

@vincentkoc
vincentkoc force-pushed the fix-sticky-disk-node-stdin-20260731 branch from 3f6ba3d to 5d38e17 Compare July 31, 2026 19:03
@vincentkoc vincentkoc changed the title fix(test): avoid workflow heredoc deadlocks fix(test): avoid macOS release gate deadlocks Jul 31, 2026
@vincentkoc

Copy link
Copy Markdown
Member Author

Maintainer gate closeout:

  • exact reviewed head 5d38e176b294ff2343066dd6406240a12d2bd8df: 68 successful check runs, zero pending, zero failed
  • ClawSweeper rank-up move satisfied: exact-head CI completed green
  • repo-native full local suite completed instead of deadlocking; both changed fixtures passed
  • the suite then reported 26 current-main baseline failures outside this PR's two test files (Discord shared mock, Telegram context recovery, browser macOS /private/tmp normalization, and QA catalog/session-store expectations)
  • those failures are being repaired in the follow-up release-validation branch/PR set before the frozen full release rerun

The local full-suite failure is therefore documented baseline noise, not a regression from this PR. Scoped proof remains 130 passed / 1 skipped plus the 10-run release-reuse stress loop.

@vincentkoc
vincentkoc merged commit a26f6c8 into main Jul 31, 2026
98 of 104 checks passed
@vincentkoc
vincentkoc deleted the fix-sticky-disk-node-stdin-20260731 branch July 31, 2026 22:19
vincentkoc added a commit that referenced this pull request Jul 31, 2026
…odels-20260729

* origin/main:
  fix(tui): canonical terminal outcomes, cancellation, and error privacy (#117044)
  fix(cron): avoid phantom message tool guidance (#116908)
  fix(test): avoid macOS release gate deadlocks (#116972)
  fix(openai): canonical Chat cache-hit and billing accounting (#117043)
  fix(memory-wiki): salvage human Notes before pruning imported source pages (#102294)
  fix(memory): suggest reindex, not --fix, for a missing qmd index (#116958)
  chore(msteams): add private Gateway QA adapter
  fix(ui): make session controls and failures accessible (#117019)
  docs: fix tilde paths in CLI output examples (#114595)
  fix(plugins): canonical discovery diagnostics and deterministic lifecycles (#117025)
  fix(ui): honor Gateway readiness abort and subscription ownership (#117048)
  fix(updater): harden launchd replacement timing (#117030)
  fix(gateway): preserve static asset HEAD representation metadata (#117049)
  fix(gateway): abort embeddings when clients disconnect (#116146)
  fix(googlechat): retain fallback thread continuity (#117053)
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 1, 2026
Fix macOS test harness deadlocks in workflow and release evidence fixtures.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant