Skip to content

test(qa): assert the failed child status lands once in parent history - #204367

Merged
obviyus merged 1 commit into
mainfrom
fix/qa-empty-completion-recovery
Nov 24, 2026
Merged

obviyus merged 1 commit into
mainfrom
fix/qa-empty-completion-recovery

Conversation

@obviyus

@obviyus obviyus commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Closes #204267. The QA smoke scenario subagent-empty-completion-recovery asserted the child delivery failure notice that #204178 removed. #204299 already replaced that notice assertion with "the parent's completion turn consumes the failed child outcome exactly once" (provider-request count). The scenario still did not check the new contract where it lives: the parent's history.

Change (test only)

The scenario now reads the parent transcript after the child fails, and again after the Gateway restart, and asserts:

  • exactly one entry carries the failed child's status (the [Internal task completion event] input or a subagent-completion entry), and it is hidden (display: false) but model-visible;
  • no run-failed-before-reply row and no displayed subagent-* row (the removed "System" dump of the child's raw result and the "delivery delayed" row);
  • the restart does not change any of this.

The existing checks stay unchanged: failed terminal outcome, one real write, two tool-free finalizations, no fabricated result, one parent completion request, and no replay after the restart.

Production-code line delta: 0 (scenario YAML only, +21 −2).

Evidence

- subagent-empty-completion-recovery now reads the parent transcript: exactly one hidden model-visible status entry for the failed child, no run-failed-before-reply row, no displayed subagent-* dump, unchanged after Gateway restart.

Closes #204267

Co-authored-by: obviyus <[email protected]>
@clawsweeper

clawsweeper Bot commented Nov 24, 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.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 24, 2026
@obviyus
obviyus merged commit b5263df into main Nov 24, 2026
95 checks passed
@obviyus
obviyus deleted the fix/qa-empty-completion-recovery branch November 24, 2026 04:10
@obviyus

obviyus commented Nov 24, 2026

Copy link
Copy Markdown
Collaborator Author

Landed as b5263df. The scenario now checks the parent transcript, before and after the Gateway restart: exactly one hidden, model-visible status entry for the failed child, no run-failed-before-reply row and no displayed child-result dump. Proof: the scenario passed locally in the smoke-ci lane, and all six QA Smoke CI shards were green on this head.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 24, 2026
…openclaw#204367)

## What Problem This Solves

Closes openclaw#204267. The QA smoke scenario `subagent-empty-completion-recovery` asserted the child delivery failure notice that openclaw#204178 removed. openclaw#204299 already replaced that notice assertion with "the parent's completion turn consumes the failed child outcome exactly once" (provider-request count). The scenario still did not check the new contract where it lives: the parent's history.

## Change (test only)

The scenario now reads the parent transcript after the child fails, and again after the Gateway restart, and asserts:

- exactly one entry carries the failed child's status (the `[Internal task completion event]` input or a `subagent-completion` entry), and it is hidden (`display: false`) but model-visible;
- no `run-failed-before-reply` row and no displayed `subagent-*` row (the removed "System" dump of the child's raw result and the "delivery delayed" row);
- the restart does not change any of this.

The existing checks stay unchanged: failed terminal outcome, one real write, two tool-free finalizations, no fabricated result, one parent completion request, and no replay after the restart.

Production-code line delta: 0 (scenario YAML only, +21 −2).

## Evidence

- Head, same lane as CI (`OPENCLAW_BUILD_PRIVATE_QA=1 pnpm build qaRuntime`, then `node openclaw.mjs qa run --qa-profile smoke-ci --scenario subagent-empty-completion-recovery`): `passed=1 failed=0`.
- Parent transcript on head (synthetic run): the child status is one hidden `openclaw.runtime-context` entry carrying `[Internal task completion event]` with the child session key. There is no `subagent-completion` entry (the completion turn consumed it) and no `run-failed-before-reply` row.
- Base (`main` after openclaw#204299): the old scenario passes too, so this PR does not repair a red; it adds the history assertions that openclaw#204299 left out.

Co-authored-by: Ayaan Zaidi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. extensions: qa-lab size: XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

QA smoke: subagent-empty-completion-recovery fails on main since child history delivery

1 participant