Skip to content

fix: keep timing metadata tests independent of inherited settings - #147112

Merged
steipete merged 1 commit into
mainfrom
codex/test-timing-metadata-env
Sep 13, 2026
Merged

steipete merged 1 commit into
mainfrom
codex/test-timing-metadata-env

Conversation

@steipete

@steipete steipete commented Sep 13, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes a tooling test failure when the parent test run sets OPENCLAW_TEST_PROJECTS_TIMINGS=0: the timing-history test expects a file that the disabled writer never creates, producing ENOENT.

User Impact

Developers can run this tooling test with timing collection disabled. There is no production behavior change.

Why This Change Was Made

The case explicitly opts into timing persistence before its first write. Existing teardown restores the inherited setting, and every assertion remains unchanged.

Evidence

  • Complete owner file with inherited 0: reproduced the exact failure (123 passed, 1 failed), then passed all 124 cases after the fix.
  • Normal environment: all 124 owner cases and 6 timing-writer sibling cases passed.
  • Changed gate and fresh independent review passed; source inversion confirms the one-line change preserves every other byte.

Local proof used the matched installed graph at f3bdcc10. The branch is now rebased onto ec049f94608; the one-line patch and affected test, timing writer, runner, and setup are unchanged. Dependency files have advanced, so local proof was not relabeled as current-graph proof; fresh exact-head CI is pending. The prior UI performance failure and diagnostic setup failures remain recorded. No runtime-performance claim.

@clawsweeper

clawsweeper Bot commented Sep 13, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@steipete
steipete marked this pull request as ready for review September 13, 2026 15:03
@openclaw-barnacle openclaw-barnacle Bot added size: XS maintainer Maintainer-authored PR labels Sep 13, 2026
@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. 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. labels Sep 13, 2026
@clawsweeper

clawsweeper Bot commented Sep 13, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 13, 2026, 2:18 PM ET / 18:18 UTC (Revision 2).

ClawSweeper review

What this changes

The PR explicitly enables timing persistence in one test so an inherited disabled setting cannot prevent its expected file from being created.

Merge readiness

✅ Ready for maintainer review

This remains a useful, narrowly scoped test repair missing from current main. No actionable correctness or security findings remain, and the maintainer-authored PR is protected from automated closure.

Priority: P3
Reviewed head: 678297952359096505b40f16984c6ced5fc073c0

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A minimal, well-targeted isolation repair with preserved assertions and relevant reported before/after validation.
Proof confidence 🌊 off-meta tidepool Not applicable: The maintainer-authored test-only repair is exempt from external runtime proof; its reported owner-suite runs directly exercise the changed test precondition, with the dependency-graph limitation explicitly recorded.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: The maintainer-authored test-only repair is exempt from external runtime proof; its reported owner-suite runs directly exercise the changed test precondition, with the dependency-graph limitation explicitly recorded.
Evidence reviewed 7 items Verified introduced change: The pinned merge-base-to-head diff contains only the test-local environment override; assertions and production code are unchanged.
Failure mechanism and cleanup: The timing writer returns without writing when OPENCLAW_TEST_PROJECTS_TIMINGS is 0. The affected test calls the actual writer and later reads its output; its existing afterEach calls vi.unstubAllEnvs(), restoring the inherited setting.
Current-main necessity: The fetched main revision still contains the persistence test without the timing-enable override.
Findings None None.
Security None None.

How this fits together

OpenClaw’s test runner records shard durations for later scheduling. This test checks that selected-file timing records preserve existing whole-suite history.

flowchart LR
  A[Inherited environment] --> B[Test-local timing override]
  B --> C[Test runner]
  D[Selected test files] --> C
  C --> E[Timing writer]
  E --> F[Temporary timing history]
  F --> G[Preservation assertions]
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Tests +1. Total +1 across 1 file.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 1 0 +1
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 1 1 0 +1

Review metrics

None.

Technical review

Best possible solution:

Keep the persistence precondition local to this test while preserving the runner’s supported timing-disable setting and existing history assertions.

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

Yes, source establishes the trigger: run the affected main-branch test with OPENCLAW_TEST_PROJECTS_TIMINGS=0 and its real writer skips the file later read by the assertion. Execution was not performed in this read-only review.

Is this the best way to solve the issue?

Yes, the test-local override supplies its required persistence precondition and uses existing environment cleanup without altering production defaults.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 09777da3faff.

Labels

Label justifications:

  • P3: This repairs test isolation without changing production behavior or weakening assertions.
  • 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: The maintainer-authored test-only repair is exempt from external runtime proof; its reported owner-suite runs directly exercise the changed test precondition, with the dependency-graph limitation explicitly recorded.

Evidence

What I checked:

  • Verified introduced change: The pinned merge-base-to-head diff contains only the test-local environment override; assertions and production code are unchanged. (test/scripts/test-projects-build-admission.test.ts:430, 678297952359)
  • Failure mechanism and cleanup: The timing writer returns without writing when OPENCLAW_TEST_PROJECTS_TIMINGS is 0. The affected test calls the actual writer and later reads its output; its existing afterEach calls vi.unstubAllEnvs(), restoring the inherited setting. (scripts/lib/vitest-shard-timings.mts:78, 678297952359)
  • Current-main necessity: The fetched main revision still contains the persistence test without the timing-enable override. (test/scripts/test-projects-build-admission.test.ts:429, 09777da3faff)
  • Release boundary: The latest supplied release contains the earlier timing-metadata suite but not the affected inherited-selection persistence case or this override; no shipped-fix claim applies. (test/scripts/test-projects-build-admission.test.ts:428, 3a9d69db306c)
  • Area history and routing: Current-main history shows repeated timing-runner work by Peter Steinberger; GitHub commit metadata maps the relevant earlier work to steipete. Local blame and older-head comparison could not complete because required historical objects were unavailable, so no line-introduction attribution is asserted. (test/scripts/test-projects-build-admission.test.ts, 47ee12ee2303)
  • Validation and review continuity: The captured PR body reports 123 passing cases and one ENOENT failure before the fix with inherited timing collection disabled, then 124 passing cases afterward, plus six sibling cases in the normal environment. It explicitly limits these results to the earlier installed dependency graph. The previous completed review retained no findings; no tests were executed during this read-only review. (678297952359)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

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-09-13T15:12:01.184Z sha 619e02a :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the codex/test-timing-metadata-env branch from 619e02a to 6782979 Compare September 13, 2026 18:11
@steipete
steipete merged commit 3da6095 into main Sep 13, 2026
121 of 122 checks passed
@steipete
steipete deleted the codex/test-timing-metadata-env branch September 13, 2026 18:47
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

vincentkoc added a commit that referenced this pull request Sep 13, 2026
* commit '28887b564210326174413d0d8ade72b38268d5f3': (1827 commits)
  fix(qa): bind coverage IDs to producer assertions (#144000)
  fix(linux): explain FreeBSD desktop setup prerequisites (#147211)
  fix(memory): split embedding batches rejected for an input array item cap (#139541)
  test: isolate timing metadata persistence from inherited settings (#147112)
  refactor(status): retire test-only helper publication (#147071)
  improve: reduce workspace agent lookup work for large fleets (#147144)
  refactor(macos): share connect credential selection (#144214)
  fix(plugins): restore Slack onboarding after core updates (#147109)
  refactor: share ANSI compatibility matching (#146998)
  fix(test): settle Models catalog before picker open (#147215)
  test(ui): reuse panel tab drag fixture (#147250)
  fix(install): use system Node for FreeBSD CLI setup (#147204)
  fix(cli): explain MCP probes with no enabled servers (#147216)
  docs: require UI screenshots in chat and PR (#147263)
  docs(skills): clarify remote gog OAuth setup for Gateway hosts (#145945)
  test: replace idle account catalog waits with synchronization (#147228)
  feat(qa): preserve maturity decision context (#147219)
  feat(macos): clarify agent activity in native chat (#147197)
  fix(runtime): complete Bun compatibility follow-ups (#147085)
  fix(ui): release closed chat panes after queued updates (#147240)
  ...
vincentkoc added a commit that referenced this pull request Sep 13, 2026
* commit 'ac59d5e09eb468dc23cf95e447608b57e71b52af': (176 commits)
  improve(gateway): avoid redundant startup preflight work (#147285)
  test(macos): observe readiness cancellation and deadline ownership (#145056)
  fix(ci): route QA Profile Evidence to its run-status owner test (#147293)
  fix(install): preserve runtime links when Node validation fails (#147221)
  test(auto-reply): reuse memory session fixtures (#147262)
  fix: hide subagent sessions from Activity (#147253)
  ci: record resources for slow runtime test commands (#147254)
  fix(update): recognize FreeBSD boot identities in triage leases (#147243)
  refactor(active-memory): share closing tag line scan (#147031)
  fix: resume Settings autosave after Reload Config (#147136)
  fix(cli): keep conversation context after cancellation (#147139)
  fix(channels): make system-agent approval cards actionable (#147152)
  refactor: retain shared database handles until their last worker closes (#147246)
  refactor(slack): share workspace-qualified target resolution (#147024)
  refactor(msteams): remove duplicate quoted-table test (#147270)
  fix(qa): bind coverage IDs to producer assertions (#144000)
  fix(linux): explain FreeBSD desktop setup prerequisites (#147211)
  fix(memory): split embedding batches rejected for an input array item cap (#139541)
  test: isolate timing metadata persistence from inherited settings (#147112)
  refactor(status): retire test-only helper publication (#147071)
  ...
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 14, 2026
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: XS 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