Skip to content

refactor(qa): move restart and policy scenarios to YAML - #101063

Merged
RomneyDa merged 1 commit into
mainfrom
dallin/wave2-channel-restart-config
Jul 6, 2026
Merged

RomneyDa merged 1 commit into
mainfrom
dallin/wave2-channel-restart-config

Conversation

@RomneyDa

@RomneyDa RomneyDa commented Jul 6, 2026

Copy link
Copy Markdown
Member

What Problem This Solves

Resolves a QA ownership problem where restart/resume, replay dedupe, allowlist reload, WhatsApp access-policy, and pairing-gate coverage remained split across imperative channel runtimes instead of the canonical scenario catalog and shared flow host.

Why This Change Was Made

Moves the assigned behavior family into canonical YAML flow scenarios for Slack, WhatsApp, and Matrix, while keeping transport-native evidence only where normalized state is insufficient. The change deletes the replaced imperative owners and obsolete tests, adds the minimal Matrix observer and WhatsApp group adapter support needed by shared flows, and teaches the shared config-mutation host how to observe intentionally deferred restarts.

Telegram was inventoried and has no imperative owner in this behavior family. Routing, commands, threads, and infrastructure lanes are unchanged.

User Impact

QA maintainers can run these restart and configuration behaviors through one canonical catalog and shared execution path across QA Channel, live adapters, and Crabline. This reduces duplicate scenario logic and makes parity gaps visible in YAML rather than channel-specific runtime code.

Evidence

  • Blacksmith Testbox tbx_01kww4yt1d8bdx7f9n025as70g (quick-crab), provider blacksmith-testbox.
  • Focused validation: 265 tests passed across QA Lab and Matrix scenario/runtime suites.
  • QA Channel: slack-restart-resume passed with mock OpenAI.
  • Crabline bridge: matrix-restart-resume passed.
  • Canonical live Matrix adapter: restart/resume, post-restart continuation, replay dedupe, and allowlist hot reload passed 4/4.
  • Review-fix reruns: replay dedupe and allowlist hot reload each passed independently after parity corrections.
  • Formatting: oxfmt --check passed for all 26 changed files.
  • Autoreview: .agents/skills/autoreview/scripts/autoreview --mode local --stream-engine-output returned clean with no accepted/actionable findings.
  • Exact-head delegated check:changed reached full typecheck; the remote sparse-sync checkout omitted tracked extensions/qa-lab/src/mantis/**, producing only Cannot find module './mantis/cli.js'. Hosted CI uses a full checkout and remains the authoritative exact-head broad gate.

@RomneyDa

RomneyDa commented Jul 6, 2026

Copy link
Copy Markdown
Member Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 6, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@RomneyDa
RomneyDa force-pushed the dallin/wave2-channel-restart-config branch from 41e0095 to 2509f22 Compare July 6, 2026 17:46
@RomneyDa

RomneyDa commented Jul 6, 2026

Copy link
Copy Markdown
Member Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 6, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper

clawsweeper Bot commented Jul 6, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 6, 2026, 2:44 PM ET / 18:44 UTC.

Summary
Moves Slack, WhatsApp, and Matrix restart, replay-dedupe, allowlist hot-reload, access-policy, and pairing-gate QA coverage from imperative runtime scenarios into canonical YAML flow scenarios, with small Matrix observer and WhatsApp group adapter support.

PR surface: Source -390, Tests -170, Other +866. Total +306 across 26 files.

Reproducibility: not applicable. as a QA refactor PR rather than a bug report. Behavior preservation is source-reviewable through the YAML-to-flow mapping and the PR body reports focused Testbox, QA Channel, Crabline, and Matrix live runs.

Review metrics: none identified.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🦞 diamond lobster
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • none.

Risk before merge

  • [P1] This read-only review did not rerun the live channel scenarios; merge confidence depends on the PR's reported Testbox/live QA proof and the green exact-head hosted checks remaining current.

Maintainer options:

  1. Decide the mitigation before merge
    Keep the YAML catalog as the single owner for this behavior family and land the refactor with the reported live QA and exact-head CI evidence intact, without restoring duplicate imperative scenario owners.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • No ClawSweeper repair lane is needed because this PR has no actionable review finding; it should proceed through normal maintainer merge gates.

Security
Cleared: The diff changes QA scenario files and test harness adapters only; no new dependency, workflow, secret, install, publish, or third-party execution surface was introduced.

Review details

Best possible solution:

Keep the YAML catalog as the single owner for this behavior family and land the refactor with the reported live QA and exact-head CI evidence intact, without restoring duplicate imperative scenario owners.

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

Not applicable as a QA refactor PR rather than a bug report. Behavior preservation is source-reviewable through the YAML-to-flow mapping and the PR body reports focused Testbox, QA Channel, Crabline, and Matrix live runs.

Is this the best way to solve the issue?

Yes. The canonical scenario catalog and shared flow runner are the maintainable owners for these QA behaviors, and the PR removes the duplicate imperative scenario definitions instead of keeping two sources of truth.

AGENTS.md: found and applied where relevant.

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

Label changes

Label changes:

  • add P3: This is a maintainer-authored QA refactor with green exact-head checks and no user-facing runtime defect found in review.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster 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: The contributor proof gate is not applicable to this maintainer-authored PR; the PR body still reports Testbox, focused QA, Crabline, live Matrix, formatting, autoreview, and hosted CI evidence.

Label justifications:

  • P3: This is a maintainer-authored QA refactor with green exact-head checks and no user-facing runtime defect found in review.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster 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 contributor proof gate is not applicable to this maintainer-authored PR; the PR body still reports Testbox, focused QA, Crabline, live Matrix, formatting, autoreview, and hosted CI evidence.
Evidence reviewed

PR surface:

Source -390, Tests -170, Other +866. Total +306 across 26 files.

View PR surface stats
Area Files Added Removed Net
Source 9 34 424 -390
Tests 6 58 228 -170
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 11 866 0 +866
Total 26 958 652 +306

What I checked:

  • Repository policy applied: Root AGENTS.md and the scoped extensions guide were read; the review treated bundled plugin and QA scenario ownership as the relevant boundary. (AGENTS.md:1)
  • YAML flow runner supports the moved scenario actions: The current flow runner resolves YAML transport actions including sendInbound, waitForOutbound, waitForNoOutbound, resetTransport, set, assert, and call, which are the primitives used by the new scenarios. (extensions/qa-lab/src/scenario-flow-runner.ts:155, 9ef7fff57098)
  • Runtime API exposes the shared transport state helpers: The runtime API provides getTransportSnapshot and resetTransport, matching the new YAML scenarios' use of outbound counts and bus resets. (extensions/qa-lab/src/scenario-runtime-api.ts:314, 9ef7fff57098)
  • Deferred restart observation is handled in the shared host: The PR adds a waitForConfigRestartSettle branch for restart delays beyond the mutation timeout, with a focused test that exercises the 300000ms deferred-restart case. (extensions/qa-lab/src/suite-runtime-gateway.ts:86, 2509f22b7d0a)
  • Matrix observer path supports allowlist hot-reload YAML: The PR head lets Matrix sendInbound use the observer actor when senderId is observer, and exposes driver/observer user IDs to YAML config patches. (extensions/qa-matrix/src/adapter.runtime.ts:162, 2509f22b7d0a)
  • WhatsApp adapter supports group-target YAML scenarios: The PR head switches WhatsApp target resolution and outbound bus addressing based on the logical conversation kind before sending inbound messages. (extensions/qa-lab/src/live-transports/whatsapp/adapter.runtime.ts:122, 2509f22b7d0a)

Likely related people:

  • RomneyDa: Authored the exact PR head and requested ClawSweeper re-review on the maintainer-labeled PR, so they are the clearest owner for follow-up on this branch. (role: current PR owner; confidence: high; commits: 2509f22b7d0a; files: extensions/qa-lab/src/live-transports/whatsapp/adapter.runtime.ts, extensions/qa-matrix/src/adapter.runtime.ts, qa/scenarios/channels/matrix-restart-resume.yaml)
  • Gustavo Madeira Santana: Recent history shows Matrix QA split and QA Lab runtime expansion work in the same QA Lab and Matrix adapter area. (role: recent area contributor; confidence: medium; commits: 82a2db71e892, 4db162db7f3e, 25445a9f2e86; files: extensions/qa-lab/src/scenario-flow-runner.ts, extensions/qa-matrix/src/adapter.runtime.ts)
  • Vincent Koc: Recent QA Lab history includes broken-turn recovery scenario work and release QA stabilization near the scenario runtime surface. (role: adjacent QA contributor; confidence: medium; commits: 900681751da1, e085fa1a3ffd; files: extensions/qa-lab/src/scenario-flow-runner.ts, extensions/qa-lab/src/suite-runtime-gateway.ts)
  • Peter Steinberger: Recent QA runner seam and multipass expectation commits touched adjacent QA infrastructure and are useful routing context if the shared runner contract needs review. (role: adjacent owner; confidence: low; commits: 943cb472749f, 5cc4426f88af; files: extensions/qa-lab/src/scenario-flow-runner.ts, extensions/qa-lab/src/suite-runtime-gateway.ts)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

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.

How this review workflow works
  • 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.

@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 6, 2026
@RomneyDa
RomneyDa merged commit 627f698 into main Jul 6, 2026
120 of 124 checks passed
@RomneyDa
RomneyDa deleted the dallin/wave2-channel-restart-config branch July 6, 2026 18:50
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Jul 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

extensions: qa-lab 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: XL 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