Skip to content

fix(ci): restore lifecycle test reliability - #138238

Merged
steipete merged 1 commit into
mainfrom
codex/fix-attempt-test-runtime
Sep 4, 2026
Merged

steipete merged 1 commit into
mainfrom
codex/fix-attempt-test-runtime

Conversation

@steipete

@steipete steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

What Problem This Solves

Resolves false CI failures in browser startup, voice-call log cleanup, service-child shutdown and Code Mode denial coverage. The tests either inspected an OS resource after relinquishing it, raced the shutdown grace period, or failed in an incomplete session fixture before reaching the intended denial.

Why This Change Was Made

The browser state suite uses its existing listener seam, while separate real HTTP auth/bind tests retain network coverage. Voice logging observes the actual successful descriptor close instead of assuming the OS cannot reuse its number. The construction-uncertainty command now exits on TERM as its self-cleanup scenario requires; dedicated tests retain ignored-TERM escalation coverage.

The embedded session fixture supplies the current nested-transcript methods and classifies structured tool failures through the canonical helper. Code Mode assertions check the actual denial reason, so an unrelated fixture exception cannot satisfy the test. Three pass-through module mocks and redundant model-content recording are removed.

User Impact

No runtime behavior changes. CI continues to detect lost cleanup, incorrect execution authority and failed error reporting without depending on resource-allocation timing.

Evidence

  • Controlled port contention reproduces the browser failure; the corrected state suite passes while real bind/auth checks remain intact.
  • An actual close followed by an unrelated open reuses the same file-descriptor number and reproduces the voice assertion failure. The corrected test observes exactly one successful real close and preserves stdout error, polling and listener-cleanup assertions.
  • Pausing only the test-owned process anchor near its five-second TERM deadline reproduces the service test failure; cleanup completes after the observer expires. The cooperative candidate and all dedicated TERM escalation cases pass.
  • Unchanged current main reproduces three Code Mode failures. The corrected cases exercise the real agent loop and Code Mode guest, assert the expected refusal or unavailable global, and prove neither the original preparer nor action runs.
  • Final combined candidate: 210 tests across 16 files and seven shards pass, including all 24 service lifecycle cases. The broader resource proof previously passed 83 tests. Full combined changed-file checks pass, including core and plugin test typechecks, typed lint and all three dead-export scans. Independent Codex review of the final five-file diff is clean.

Production delta: 0. Tests/test support: +45/-34, net +11. No timeout increase, skipped assertion, configuration option or dependency change.

Related CI failures: #138189, #138205 and #138216.

@clawsweeper

clawsweeper Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added channel: voice-call Channel integration: voice-call agents Agent runtime and tooling extensions: browser size: S maintainer Maintainer-authored PR labels Sep 4, 2026
@steipete
steipete marked this pull request as ready for review September 4, 2026 11:54
@steipete steipete self-assigned this Sep 4, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. 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 4, 2026
@clawsweeper

clawsweeper Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 4, 2026, 8:02 AM ET / 12:02 UTC.

ClawSweeper review

What this changes

The PR replaces timing- and resource-reuse-sensitive lifecycle test assertions across browser control state, voice-call log cleanup, embedded-agent Code Mode denial, and service-child shutdown coverage.

Merge readiness

⛔ Blocked before merge - 1 item remains

Keep this fresh maintainer-owned PR open. It contains a focused, test-only repair for real lifecycle assertion races; fetched main still has the browser test pattern being replaced, and source review found no blocking defect in the patch.

Priority: P2
Reviewed head: ce42af56a82f3669c1b0944b937e14f4f53026a1

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused, behavior-preserving test repair with source-backed lifecycle assertions and no actionable review findings.
Proof confidence 🌊 off-meta tidepool Not applicable: This maintainer-authored, test-only PR does not change user-visible runtime behavior; the supplied body describes focused after-fix CI evidence, while this read-only review independently inspected the production owners and test boundaries.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This maintainer-authored, test-only PR does not change user-visible runtime behavior; the supplied body describes focused after-fix CI evidence, while this read-only review independently inspected the production owners and test boundaries.
Evidence reviewed 7 items Introduced scope: The verified merge-base-to-head diff changes only five test or test-support files and no production runtime files.
Browser lifecycle boundary: Browser startup delegates the real listener to the listener seam before registering the shared runtime, while shutdown clears shared state after lifecycle cleanup. The new test blocks authentication before queuing stop, so it deterministically reaches the intended serialization case without binding a port.
Current-main necessity check: The fetched-main version of the browser shared-control-state test still imports and allocates a free TCP port rather than using the listener seam, so current main has not already absorbed this central repair.
Findings None None.
Security None None.

How this fits together

These suites verify lifecycle owners around browser control startup, voice-call output, embedded-agent tool gating, and supervised child processes. They ensure CI observes the intended cleanup or denial result without relying on OS scheduling or incomplete test doubles.

flowchart LR
  A[Lifecycle test inputs] --> B[Browser control state]
  A --> C[Voice-call log stream]
  A --> D[Embedded-agent tool gate]
  A --> E[Child process supervisor]
  B --> F[Lifecycle owners]
  C --> F
  D --> F
  E --> F
  F --> G[Deterministic CI assertions]
Loading

Before merge

  • Resolve merge risk (P1) - Exact-head CI was still in progress in the captured PR state; the reported combined test results in the PR body are useful evidence but do not replace normal completion of those checks.
Agent review details

Security

None.

PR surface

Tests +11. Total +11 across 5 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 5 45 34 +11
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 5 45 34 +11

Review metrics

Metric Value Why it matters
Production versus test delta production +0/-0; tests and test support +45/-34 The patch is confined to reliability coverage and adds no runtime behavior or configuration surface.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Land the focused test-only repair once the exact-head checks complete, retaining the real browser bind/auth and ignored-TERM escalation coverage as the sibling proofs for the seams now mocked or made cooperative.
  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 test-only repair once the exact-head checks complete, retaining the real browser bind/auth and ignored-TERM escalation coverage as the sibling proofs for the seams now mocked or made cooperative.

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

No reviewer-side execution was run because this is a read-only review. The source establishes the reported races: a released descriptor can be reused, the original browser test did not ensure startup had reached its gate, and the old child command ignored TERM through the grace window.

Is this the best way to solve the issue?

Yes. The patch corrects the affected test seams and fixtures rather than changing production lifecycle timing, cleanup ownership, or tool policy; retained sibling tests continue to exercise real listener binding and ignored-TERM escalation.

AGENTS.md: found and applied where relevant.

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

Labels

Label changes:

  • add P2: This repairs CI reliability and preserves lifecycle regression coverage without a demonstrated user-facing runtime outage.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-authored, test-only PR does not change user-visible runtime behavior; the supplied body describes focused after-fix CI evidence, while this read-only review independently inspected the production owners and test boundaries.

Label justifications:

  • P2: This repairs CI reliability and preserves lifecycle regression coverage without a demonstrated user-facing runtime outage.
  • 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 maintainer-authored, test-only PR does not change user-visible runtime behavior; the supplied body describes focused after-fix CI evidence, while this read-only review independently inspected the production owners and test boundaries.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 9607d30 adds extensions/voice-call/src/cli-call-log.test.ts:169 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 9607d302c6fd; files: extensions/voice-call/src/cli-call-log.test.ts)

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.

@steipete
steipete merged commit e7fffcf into main Sep 4, 2026
223 checks passed
@steipete
steipete deleted the codex/fix-attempt-test-runtime branch September 4, 2026 12:08
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

steipete added a commit that referenced this pull request Sep 4, 2026
Adopt the two relevant test-only corrections already landed in #138238
(e7fffcf). Supply the session methods consumed by nested tool
observation and classify structured tool failures as AgentSession does.
Keep policy-denial and never-entered action/preparer assertions intact.

The original file reproduces three failures. All 112 files and 1,666 tests
pass after this correction, with complete changed-file gates and independent
review. Launcher implementation and release candidate are unchanged.
steipete added a commit that referenced this pull request Sep 4, 2026
Merge current main and preserve the fixture cleanup from #138238. Retain
real in-memory session management, structured denial classification, and
recorded nested denial assertions while removing the redundant observation
array.

The CPU context-reader implementation remains unchanged. The combined
candidate preserves main's batching and normal Code Mode continuation.
steipete added a commit that referenced this pull request Sep 4, 2026
Adopt the SessionManager fixture and structured-result classification from
#138238, preserving the attempted hidden namespace call and the checks that
neither the original preparer nor action executes. Remove redundant pass-through
mocks with the upstream fixture.

Both files match the successful upstream CI head ce42af5 exactly. Gateway
runtime code is unchanged; this resolves the parallel test-fix merge conflict.
steipete added a commit that referenced this pull request Sep 4, 2026
* fix(cli): let the dev runner own child shutdown

The JavaScript shim and dev runner both escalated after five seconds. The
shim could kill the runner first, leaving its separately detached child
alive. Delegate termination to the runner and handle SIGHUP through its
existing signal and build-lock lifecycle. Preserve Node execution under Bun
and other shim callers' termination behavior.

Real process regressions fail before the fix and pass for SIGTERM/SIGHUP.
Runner and entrypoint tests, changed-file checks, and independent review
pass. A fresh Linux Node 24.19.0 build passes the original Gateway worker
restart scenario (Actions 33868737194).

Release-note context: source-checkout Gateway shutdown no longer abandons a
slow child when the development launcher's shutdown timers race.

* test(agents): align attempt fixtures with session contracts

Adopt the two relevant test-only corrections already landed in #138238
(e7fffcf). Supply the session methods consumed by nested tool
observation and classify structured tool failures as AgentSession does.
Keep policy-denial and never-entered action/preparer assertions intact.

The original file reproduces three failures. All 112 files and 1,666 tests
pass after this correction, with complete changed-file gates and independent
review. Launcher implementation and release candidate are unchanged.
steipete added a commit that referenced this pull request Sep 4, 2026
* fix(gateway): keep received work inside its state lifetime

Join original WebSocket dispatch, cooperating refreshes and connection cleanup before releasing Gateway dependencies. Retire passive approval/question/run observers without inventing durable decisions, and preserve test state until native callbacks and first browser closes settle.

Remove the unused process-local approval implementation and forwarding adapters. The refactor removes 404 production lines from the initial repair while retaining boundary regressions and moving manager tests onto the real durable path.

Verified under enforced credential-free isolation: 2,143 distinct owner/native/process tests, a final 77-test rerun, changed gates, product/UI builds and scoped-clean Codex P0 review. Protected exact-order browser replay remains a pre-merge gate; historical incomplete audits are not acceptance.

* fix(gateway): join worker cleanup before closing transport

Fence ingress without disconnecting the supervisor needed for worker cleanup,
then join received work before releasing the remaining Gateway dependencies.
Preserve exact pending-node authority during direct and restart shutdown.

Keep startup logging and sidecar acquisition owned independently of fail-fast
readiness, and retire published plugin services only through their actual owner.
Join portal cleanup before reporting sibling shutdown failures.

Record positive test-Gateway closure at its owner. Retain fixture state and
selectors after incomplete shutdown, including across module reload, without
confusing a post-close diagnostic with an unfinished producer. Cover that
boundary through an isolated real-Gateway counterfactual and regression.

Consolidate UI finalization with the shared QA cleanup owner and separate the
lazy handler registry from dispatch without changing loading or method order.
Derive handler families from typed descriptor rows and remove the old casts.

Follow-up repair for the state-lifetime boundary in #136145 and #136146.

* fix(gateway): fence worker frames during ordinary close

Reject newly received worker frames once their connection generation starts closing, while retaining queued work and its completion owners. Cover the live-socket window through the real worker protocol and a checked synthetic node sink.

Synchronize the update-failure UI test with its intended Updates recovery navigation before reopening the Inbox.

Follow-up for #136146 (Gateway received-work lifetime), addressing the shutdown-admission gap from review.

* fix(browser): join SDK-initiated MCP transport cleanup

Route SDK initialization failure and transport close through the existing
Chrome MCP process owner before native close clears the child PID. Capture
the native closer separately so concurrent callers join one cleanup path
without recursion or losing descendant ownership.

Collect startup diagnostics after cleanup and stderr completion, while
never-spawned commands skip the unused pipe. Preserve cleanup failures and
the existing launch, environment, and process-group behavior. Exercise late
stderr, descendant cleanup, forced termination, ENOENT, and backpressure
through real subprocesses.

* fix(gateway): retain supervisors after worker shutdown failure

Require connection-dependent sidecars to stop successfully before draining their supervisor transports or releasing runtime dependencies. Cover public and startup-failure shutdown, retained-owner retry, and late sidecar registration.

* test(gateway): join policy writers after releasing handler gates

Preserve policy-revocation and response-order coverage under the received-work dispatcher completion contract. Retain all held calls and release/join them in finally so tests cannot wait on their own unreleased gates.

* fix(gateway): retain execution through required shutdown

Preserve early acknowledgements while joining original raw, typed, and
agent execution through final cleanup. Cancel this Gateway's runs before
the join, and fence late admission at controller publication.

Retain failed startup acquisitions and plugin cleanup owners, preserve both
startup and cleanup errors, and prevent CLI successors after incomplete
retirement. Keep deferred startup hooks and sentinel refresh in their owner.
Remove the monolithic close factory and redundant post-abort polling.

Declare compiled plugin dependencies for the full lifecycle fixture through
the existing pretest owner. Align the QA publishing reference with main.

Validated isolated before/after regressions, original-order execution,
startup/CLI/plugin suites, full build, types, lint, and Codex review.
The protected metadata audit remains unaccepted; this is not merge approval.

Refs #136145, #136146.

* test(agents): align Code Mode fixtures with main

Adopt the SessionManager fixture and structured-result classification from
#138238, preserving the attempted hidden namespace call and the checks that
neither the original preparer nor action executes. Remove redundant pass-through
mocks with the upstream fixture.

Both files match the successful upstream CI head ce42af5 exactly. Gateway
runtime code is unchanged; this resolves the parallel test-fix merge conflict.

* test(gateway): reuse tracked agent contexts

Replace three partial agent-handler contexts with the shared fixture. The missing
execution tracker threw after admission handoff and leaked session claims into
later continuation tests. Preserve their assertions, timers, and original order.

The complete 302-case file reproduces all six CI failures before this repair and
passes afterward in the same order. Type checks, type-aware lint, formatting,
and independent Codex review pass. No production code changes.

* test: fix gateway, Signal, and UI fixture lifetimes

Reset agent database handles, validation, and terminal latches only within
retired fixture roots before deleting or recreating their files. Preserve
ordinary runtime reopen behavior and unrelated roots.

Model the pending host question in Signal's partial-delivery fixture and
assert the accepted reaction binding. Use actual Settings navigation from
independent cold UI contexts so document reloads do not abort startup
scripts and masquerade as asset failures. Preserve existing assertions.

Reproduced the Node and Signal failures locally and the UI cancellation on
Linux. The Linux owner replay passes 30 tests across six files, the full
settings suite passes seven, and the final UI revision passes both cold
routes locally. Static checks and independent source review pass. The
isolated native fixture still times out on this Mac; Linux completes its
unchanged case in 13 seconds. Protected audit acceptance and final-head
hosted checks remain separate landing requirements for PR #136146.

* test(sessions): call database reset without hook context

Wrap the participant suite teardown in a zero-argument callback. Vitest
passes TestContext to registered hooks; the reset helper now accepts an
optional root path for selective fixture retirement.

The full seven-case file reproduced four teardown failures before this
change and passes all seven afterward. Assertions and cleanup semantics
are unchanged. The callback audit found no other direct registrations.

Refs #136146, #136145.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 5, 2026
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 5, 2026
* fix(cli): let the dev runner own child shutdown

The JavaScript shim and dev runner both escalated after five seconds. The
shim could kill the runner first, leaving its separately detached child
alive. Delegate termination to the runner and handle SIGHUP through its
existing signal and build-lock lifecycle. Preserve Node execution under Bun
and other shim callers' termination behavior.

Real process regressions fail before the fix and pass for SIGTERM/SIGHUP.
Runner and entrypoint tests, changed-file checks, and independent review
pass. A fresh Linux Node 24.19.0 build passes the original Gateway worker
restart scenario (Actions 33868737194).

Release-note context: source-checkout Gateway shutdown no longer abandons a
slow child when the development launcher's shutdown timers race.

* test(agents): align attempt fixtures with session contracts

Adopt the two relevant test-only corrections already landed in openclaw#138238
(ce8b5ca). Supply the session methods consumed by nested tool
observation and classify structured tool failures as AgentSession does.
Keep policy-denial and never-entered action/preparer assertions intact.

The original file reproduces three failures. All 112 files and 1,666 tests
pass after this correction, with complete changed-file gates and independent
review. Launcher implementation and release candidate are unchanged.
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 5, 2026
…136146)

* fix(gateway): keep received work inside its state lifetime

Join original WebSocket dispatch, cooperating refreshes and connection cleanup before releasing Gateway dependencies. Retire passive approval/question/run observers without inventing durable decisions, and preserve test state until native callbacks and first browser closes settle.

Remove the unused process-local approval implementation and forwarding adapters. The refactor removes 404 production lines from the initial repair while retaining boundary regressions and moving manager tests onto the real durable path.

Verified under enforced credential-free isolation: 2,143 distinct owner/native/process tests, a final 77-test rerun, changed gates, product/UI builds and scoped-clean Codex P0 review. Protected exact-order browser replay remains a pre-merge gate; historical incomplete audits are not acceptance.

* fix(gateway): join worker cleanup before closing transport

Fence ingress without disconnecting the supervisor needed for worker cleanup,
then join received work before releasing the remaining Gateway dependencies.
Preserve exact pending-node authority during direct and restart shutdown.

Keep startup logging and sidecar acquisition owned independently of fail-fast
readiness, and retire published plugin services only through their actual owner.
Join portal cleanup before reporting sibling shutdown failures.

Record positive test-Gateway closure at its owner. Retain fixture state and
selectors after incomplete shutdown, including across module reload, without
confusing a post-close diagnostic with an unfinished producer. Cover that
boundary through an isolated real-Gateway counterfactual and regression.

Consolidate UI finalization with the shared QA cleanup owner and separate the
lazy handler registry from dispatch without changing loading or method order.
Derive handler families from typed descriptor rows and remove the old casts.

Follow-up repair for the state-lifetime boundary in openclaw#136145 and openclaw#136146.

* fix(gateway): fence worker frames during ordinary close

Reject newly received worker frames once their connection generation starts closing, while retaining queued work and its completion owners. Cover the live-socket window through the real worker protocol and a checked synthetic node sink.

Synchronize the update-failure UI test with its intended Updates recovery navigation before reopening the Inbox.

Follow-up for openclaw#136146 (Gateway received-work lifetime), addressing the shutdown-admission gap from review.

* fix(browser): join SDK-initiated MCP transport cleanup

Route SDK initialization failure and transport close through the existing
Chrome MCP process owner before native close clears the child PID. Capture
the native closer separately so concurrent callers join one cleanup path
without recursion or losing descendant ownership.

Collect startup diagnostics after cleanup and stderr completion, while
never-spawned commands skip the unused pipe. Preserve cleanup failures and
the existing launch, environment, and process-group behavior. Exercise late
stderr, descendant cleanup, forced termination, ENOENT, and backpressure
through real subprocesses.

* fix(gateway): retain supervisors after worker shutdown failure

Require connection-dependent sidecars to stop successfully before draining their supervisor transports or releasing runtime dependencies. Cover public and startup-failure shutdown, retained-owner retry, and late sidecar registration.

* test(gateway): join policy writers after releasing handler gates

Preserve policy-revocation and response-order coverage under the received-work dispatcher completion contract. Retain all held calls and release/join them in finally so tests cannot wait on their own unreleased gates.

* fix(gateway): retain execution through required shutdown

Preserve early acknowledgements while joining original raw, typed, and
agent execution through final cleanup. Cancel this Gateway's runs before
the join, and fence late admission at controller publication.

Retain failed startup acquisitions and plugin cleanup owners, preserve both
startup and cleanup errors, and prevent CLI successors after incomplete
retirement. Keep deferred startup hooks and sentinel refresh in their owner.
Remove the monolithic close factory and redundant post-abort polling.

Declare compiled plugin dependencies for the full lifecycle fixture through
the existing pretest owner. Align the QA publishing reference with main.

Validated isolated before/after regressions, original-order execution,
startup/CLI/plugin suites, full build, types, lint, and Codex review.
The protected metadata audit remains unaccepted; this is not merge approval.

Refs openclaw#136145, openclaw#136146.

* test(agents): align Code Mode fixtures with main

Adopt the SessionManager fixture and structured-result classification from
openclaw#138238, preserving the attempted hidden namespace call and the checks that
neither the original preparer nor action executes. Remove redundant pass-through
mocks with the upstream fixture.

Both files match the successful upstream CI head ce42af5 exactly. Gateway
runtime code is unchanged; this resolves the parallel test-fix merge conflict.

* test(gateway): reuse tracked agent contexts

Replace three partial agent-handler contexts with the shared fixture. The missing
execution tracker threw after admission handoff and leaked session claims into
later continuation tests. Preserve their assertions, timers, and original order.

The complete 302-case file reproduces all six CI failures before this repair and
passes afterward in the same order. Type checks, type-aware lint, formatting,
and independent Codex review pass. No production code changes.

* test: fix gateway, Signal, and UI fixture lifetimes

Reset agent database handles, validation, and terminal latches only within
retired fixture roots before deleting or recreating their files. Preserve
ordinary runtime reopen behavior and unrelated roots.

Model the pending host question in Signal's partial-delivery fixture and
assert the accepted reaction binding. Use actual Settings navigation from
independent cold UI contexts so document reloads do not abort startup
scripts and masquerade as asset failures. Preserve existing assertions.

Reproduced the Node and Signal failures locally and the UI cancellation on
Linux. The Linux owner replay passes 30 tests across six files, the full
settings suite passes seven, and the final UI revision passes both cold
routes locally. Static checks and independent source review pass. The
isolated native fixture still times out on this Mac; Linux completes its
unchanged case in 13 seconds. Protected audit acceptance and final-head
hosted checks remain separate landing requirements for PR openclaw#136146.

* test(sessions): call database reset without hook context

Wrap the participant suite teardown in a zero-argument callback. Vitest
passes TestContext to registered hooks; the reset helper now accepts an
optional root path for selective fixture retirement.

The full seven-case file reproduced four teardown failures before this
change and passes all seven afterward. Assertions and cleanup semantics
are unchanged. The callback audit found no other direct registrations.

Refs openclaw#136146, openclaw#136145.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling channel: voice-call Channel integration: voice-call extensions: browser maintainer Maintainer-authored PR P2 Normal backlog priority with limited blast radius. 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