Skip to content

fix: honor scenario drivers in generated QA commands - #131101

Merged
steipete merged 2 commits into
mainfrom
codex/qa34-coverage-driver
Aug 27, 2026
Merged

steipete merged 2 commits into
mainfrom
codex/qa34-coverage-driver

Conversation

@steipete

@steipete steipete commented Aug 27, 2026 •

Copy link
Copy Markdown
Contributor

Closes #131088

What Problem This Solves

Fixes an issue where qa coverage --match suggested suite commands that contradicted a scenario's required channel driver. Two current Crabline-only scenarios received --channel-driver live and were rejected by the same canonical selector used during suite startup.

Why This Change Was Made

The existing search projection now retains requiredChannelDriver; command grouping includes it, and rendering uses the declared value with the existing shell-quoting helper. Unconstrained defaults stay unchanged. The fix carries the prepared fact instead of rediscovering catalog data while rendering or weakening lane validation.

User Impact

Generated commands preserve explicit driver requirements and separate incompatible driver groups. Source-checkout QA users no longer need to repair a flag chosen by coverage output. JSON search results also retain the requirement. No scenario, authentication, provider, or execution policy changes.

Evidence

Both real catalog commands failed canonical selection before production edits with channelDriver=crabline: telegram-assistant-transcript-role-boundary and native-command-session-target. The completed regression table produced 5 failures and 6 passes against baseline production, then 11 passes against the candidate.

402 tests passed across eight files, covering coverage reports, generated commands, scenario catalog, lane selection, suite planning, module-flow planning, and CLI/runtime registration. The new tests parse generated commands with real CLI options and feed them to canonical selection, requiring a nonzero exact scenario set. They also protect defaults, conflicting-driver grouping, unpinned channels, and shell argument safety.

The coordinator independently ran the private built CLI for both catalog scenarios in Markdown and JSON modes with isolated HOME/config/state and the existing private-QA CLI opt-in. Each generated command selected exactly its intended scenario, count 1. Generated suite commands were not executed: this is command-generation and selection proof, not a provider/channel or scenario-run success claim.

pnpm check:changed -- extensions/qa-lab/src/coverage-report.ts extensions/qa-lab/src/coverage-report.commands.test.ts docs/concepts/qa-e2e-automation.md
OPENCLAW_BUILD_PRIVATE_QA=1 OPENCLAW_BUILD_ALL_NO_PNPM=1 node --import tsx scripts/build-all.mts qaRuntime
git diff --check

All passed. The full changed gate includes extension/test types, prepared declaration lint, formatting, architecture guards, and five additional doctor-contract checks. Worker attempts at package-manager startup/declaration preparation were sandbox-blocked; the coordinator completed the gate through normal local tooling without disabling verification. The targeted private QA runtime build passed; ordinary packaged/full-suite validation is not claimed, and QA Lab remains source-only.

Fresh independent P1 autoreview of the integrated repair and final test correction found no actionable findings (correct, confidence 0.93; original pass 0.96). Production +12/-4, net +8; tests +142; docs +4/-1. The eight production lines retain one previously discarded requirement across projection/grouping and quote it safely; no wrapper, duplicate validator, dependency, or new configuration option is introduced.

Provenance: the gap became visible after PR118542 — Telegram release validation, authored and merged by @vincentkoc on August 3, 2026, added the driver requirements. It remained after PR129340 — runnable coverage commands, authored and merged by @steipete on August 25, 2026. Local containing tags are beta-only; no stable-release regression is claimed.

CI follow-through

Initial CI33101964481 failed the plugin test boundary because the new test imported core-private shell parsing. The corrected test instead captures real POSIX-shell arguments, then uses the actual CLI options and canonical scenario selector. It starts no QA suite/provider/channel. All 11 cases, the exact import guard, and the complete changed gate passed again; independent integrated review is clean. Windows developers need Git Bash's sh on PATH; native Windows execution is not claimed.

The same initial run also measured plugins list --json at 401.8 MB against the 401 MB effective ceiling (samples 401.9/328.8/401.8). This matches shared incident130977 — Blacksmith startup-memory variance. Normal builds exclude QA Lab, and the changed report has no ordinary packaged-CLI import path. Fresh incident metadata says automation skipped implementation pending a maintainer decision on runner calibration/headroom; no active repair PR is claimed. Memory thresholds, sample policy, and verifier scheduling are unchanged. The corrected head passed exact-head CI33104409357 at 3c30df2c3e2e296726ef3805e8bb0a819a3c9c65; the native watcher reported GREEN. All 402 local owner/sibling tests also passed again on that published head, with a clean checkout. The failed initial run remains recorded, and a green run does not mean the shared memory incident is repaired. Latest ClawSweeper feedback is only a corrected-head review-started placeholder, not a published verdict or Rank-up moves; no bot approval is claimed.

Documentation: https://docs.openclaw.ai/concepts/qa-e2e-automation. AI-assisted repair; the behavior above is the release-note context.

Carry declared driver requirements through coverage search, grouping and quoted command output. Preserve unconstrained defaults and validate generated arguments through real CLI parsing and canonical lane selection. Closes #131088.
@clawsweeper

clawsweeper Bot commented Aug 27, 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 docs Improvements or additions to documentation extensions: qa-lab size: S maintainer Maintainer-authored PR labels Aug 27, 2026
@steipete
steipete marked this pull request as ready for review August 27, 2026 18:08
@steipete steipete self-assigned this Aug 27, 2026
@steipete

steipete commented Aug 27, 2026 •

Copy link
Copy Markdown
Contributor Author

Pushed test-boundary correction 3c30df2c3e2e296726ef3805e8bb0a819a3c9c65. Production is unchanged: the test no longer imports core-private shell utilities. A real POSIX shell captures argv without starting pnpm, a QA suite, a provider, or a channel; the real CLI parser and canonical selector then validate the command.

All 11 command cases passed again, as did the exact extension-test import guard and the full changed gate. Fresh independent review of the integrated final patch is clean. Test delta is now +142 lines; production remains +12/−4 (net +8).

The other failure in initial CI33101964481 was plugins-list startup memory: median 401.8 MB versus 401 MB, samples 401.9/328.8/401.8. This matches shared incident130977; fresh incident state says implementation was skipped pending a maintainer calibration/headroom decision. Normal builds exclude QA Lab. No memory threshold, sample policy, or verifier scheduling was changed, and no memory improvement is claimed.

The updated PR body retains that failure and the platform/proof limits.

Land-ready update: Exact-head CI33104409357 completed success at 3c30df2c3e2e296726ef3805e8bb0a819a3c9c65; the native watcher reported GREEN. This pass used the unchanged memory policy and does not fix or close the shared incident. Native review artifacts are validated. Latest ClawSweeper feedback is only a corrected-head started placeholder, not a published verdict or Rank-up moves; no bot approval is claimed.

Coordinator reran all 402 tests across eight files on the published head, clean afterward:

node scripts/run-vitest.mjs extensions/qa-lab/src/coverage-report.commands.test.ts extensions/qa-lab/src/coverage-report.test.ts extensions/qa-lab/src/scenario-catalog.test.ts extensions/qa-lab/src/scenario-lane.test.ts extensions/qa-lab/src/suite-planning.test.ts extensions/qa-lab/src/suite-planning-module-flows.test.ts extensions/qa-lab/src/cli.test.ts extensions/qa-lab/src/cli.runtime.test.ts

The final boundary guard and complete changed gate also passed:

node --import tsx scripts/check-no-extension-test-core-imports.ts
pnpm check:changed -- extensions/qa-lab/src/coverage-report.ts extensions/qa-lab/src/coverage-report.commands.test.ts docs/concepts/qa-e2e-automation.md

Private runtime build and real local CLI/selection proof are recorded in the PR body. No suite/provider/channel run or native Windows execution is claimed. Proceeding through native prepare/merge gates; no bypass.

@steipete
steipete merged commit 19be0f6 into main Aug 27, 2026
147 checks passed
@steipete
steipete deleted the codex/qa34-coverage-driver branch August 27, 2026 18:58
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 28, 2026
* fix: honor scenario drivers in generated QA commands

Carry declared driver requirements through coverage search, grouping and quoted command output. Preserve unconstrained defaults and validate generated arguments through real CLI parsing and canonical lane selection. Closes openclaw#131088.

* test: capture generated QA commands through the shell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation extensions: qa-lab maintainer Maintainer-authored PR size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: QA coverage commands ignore required channel drivers

1 participant