🤖 fix: keep stopped sub-agents stopped after restart - #4172
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
@codex review |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4b46c7bd60
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Addressed all four findings in 52cf430:
All 2,050 focused service/history tests and make static-check pass. Live retry and explicit pause/resume semantics remain unchanged. |
|
@codex review |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 52cf430737
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Addressed both latest findings:
All 2,149 service/history tests and local static checks pass. |
|
@codex review |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1c20871bd8
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Addressed the latest findings:
All 2,152 service/history tests and local static checks pass. Production delta remains subtractive: +175/-180, net -5. |
|
@codex review |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
|
CI hit a WorkflowRunner sandbox null-reference error in an untouched test (expected the deliberately thrown agent error). The exact file passes locally: all 79 tests in 2.75s. Retrying the Unit job without code changes; all other code/build jobs passed. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 197308eed9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Addressed both startup-race findings:
All 2,154 service/history tests (~30s) and local static checks pass. Existing cancellation/checkpoint and inactive-workflow queue-drain coverage remains green. Production delta: +188/-191, net -3. |
|
@codex review |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1b59bb27ec
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Addressed all three findings:
All 2,170 service/history/shared-helper tests and make static-check pass. Startup read plumbing, send settings, diagnostics, and ID normalization are shared to retain a net-negative production delta (+271/-273, net -2), without dropping diagnostics or safety checks. |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9e7fb2dd08
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
|
Addressed both findings:
All 2,173 service/history tests and local static checks pass. Production delta remains +302/-304, net -2. |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b9f2f59f16
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…dates _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$236.73`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=236.73 -->
_Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$264.85`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=264.85 -->
<!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=264.85 -->
Reuse bulk metadata for identity admission and interrupted retry derivation, retaining the snapshot across deferred reruns. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$316.14`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=316.14 -->
Restore durable parent guidance behind restarted interactive questions without dispatching a turn. Reuse per-ID queue dedupe and settlement; preserve Stop and opt-out precedence. Validation: 1083 targeted regression tests; make static-check. Production ledger: +98/-101, net -3.
Share live/restored guidance background handoff and cancellation settlement. Reuse transient ownership for startup admission, recovery, and empty compaction checks; detach abandoned probes before deferred physical cleanup while preserving adopted sessions. Validation: 1093 tests passed across five lifecycle suites; make static-check passed. Production ledger: +83/-83, net zero.
Distinguish durable Stop/opt-out from indeterminate startup blockers and settle stopped child lifecycles before queued work is admitted. Preserve question waits, read-failure blockers, and live work. Suppress redundant nested handle drains until the complete task-stop batch settles. Simplify stale-starting recovery and reuse the initial queue drain; avoid creating sessions just to clear absent queues. Validation: 1228 tests passed across six lifecycle suites; make static-check passed. Production ledger: +52/-50 (net +2); the lower PR remains neutral against its prior -2 ledger.
Fail closed on preference I/O errors, retry boundedly, and discard rejected load caches without losing owed Stop markers or unknown opt-out state. Cancel only captured durable guidance IDs during stop settlement and contain each startup normalization failure independently. Consolidate preference defaulting and replace manual startup-tail scanning with findLast using identical predicates. Validation: 1810 tests passed across 38 lifecycle/session files, including tail/goal/compaction; make static-check passed. Production ledger: +72/-72, net zero.
## Summary Record the user preference to use `gh stack` for GitHub-native stacked PRs, keeping every PR linked in the native stack rather than only chaining base branches. `AGENTS.md` points to `docs/AGENTS.md`; the generated built-in skill copy is synchronized. ## Stack Fourth PR in native stack #4174, directly above #4194: #4172 → #4173 → #4194 → this PR. Stack membership is managed with `gh stack link`. ## Validation - Formatting checked against the resolved `AGENTS.md` target. - `make static-check` and `git diff --check`. - No prose-only assertion tests added. ## Subtractive ledger Production logic: +0 / −0. One documentation line and its generated string mirror; no behavior changes or unrelated subtractions. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$459.97`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=459.97 -->
59d03f9 to
e52e2a6
Compare
This comment has been minimized.
This comment has been minimized.
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
This comment has been minimized.
This comment has been minimized.
1 similar comment
This comment has been minimized.
This comment has been minimized.
|
@codex review Retrying the unchanged rebased head after the checkout-service failures. Successful reviews on this stack confirm the published refs are available; please complete code and security review. No source changes or gate bypasses have been made. |
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
Both code and security reviews now successfully approve e52e2a6 with no findings. The eleven earlier missing-ref checkout errors are superseded by these successful reviews and are being marked outdated. All build/test checks pass; rerunning the comments/Required gate after cleanup. |
## Stack **Stacked on #4172** (`fix-stopped-task-startup`). Merge the startup fix first, then retarget this PR to `main`. This diff contains only the loading UI cleanup. ## Summary Remove the permanent transcript gutter reserved for the transient “Loading messages…” badge. Initial uncached history keeps the existing Vercel-style shimmer skeleton; cached replay keeps real rows visible and shows an accessible shared shimmer strip over the existing dock edge without occupying transcript space. ## Implementation - Replace the spinner badge with a zero-layout-height cached-replay shimmer strip and delete unconditional transcript bottom padding. Initial loads reuse the existing full shimmer skeleton. - Preserve the existing skeleton/reveal gate, sticky composer, zero-height bottom sentinel, and scroll ownership—no new timing state, effects, or animation implementation. - Update stories to assert zero reserved space, stable dock/message/scroll geometry through catch-up, compact-tail visibility, active feedback, and read-only replay; pin an initial-loading phone story. ## Validation - All 65 hydration/scroll/story-contract tests and all 7 chat geometry integration tests pass after stacking. - `make static-check` passes on the integrated stack. - Three Chromium Storybook plays pass, including composed Pixel metadata and actual 390px phone bounds. Earlier manager validation also covered a 375px phone. Cached catch-up preserves dock/message/scroll geometry, and the full initial shimmer stays onscreen with zero reserved padding or document scroll. ## Subtractive ledger **P1: 20 production lines added, 23 removed; net −3.** Removed the separate loading badge and the permanent gutter it required, reusing shared shimmer for an accessible overlay confined to the existing dock edge. No unrelated offsets. ## Risks Removing reserved padding changes settled transcript geometry intentionally. Regression checks protect bottom anchoring, cached catch-up stability, and narrow-screen composer visibility. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$236.73`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=236.73 -->
## Summary Make PR readiness use GitHub's complete check rollup instead of the name-deduplicated `gh pr checks` projection, and record the preference for `gh stack` to manage native stacked PRs. ## Background On #4194, successful `Required` and `Codex Comments` checks from one workflow run hid two still-failing checks with the same names in another run. The previous readiness workflow incorrectly reported success. The new discovery path was tested against that live failure and returns exit 1 with both failing job URLs. ## Implementation - Share paginated, commit-pinned head/merge check discovery between the readiness waiter and log extractor; retain independent suite results while relying on GitHub's rollup to exclude superseded attempts. - Fail closed on API errors or incomplete pagination, and keep unknown check states pending. - Do not infer that a pending Pixel status explains GitHub's `BLOCKED` state. Failure output prioritizes failing checks and identifies their commits. - Run offline behavioral regressions in CI and update AGENTS.md plus its generated skill copy. ## Stack Remains directly above #4194 in native stack #4174; #4172 and #4173 have merged. ## Validation - 19 new PR-check regressions and 12 existing Codex-gate tests passed. - Shellcheck, `make static-check`, and `git diff --check` passed. - Live reproduction on #4194 surfaced both hidden failures from run `34385271008`; retrying that exact run subsequently passed. ## Risks Readiness becomes intentionally stricter: independent failures and unexplained GitHub blockers can no longer be masked by same-name successes or optional Pixel statuses. ## Production ledger Workflow scripts/config: +100 / −49 (net +51), excluding tests and documentation. Removed repeated state predicates, duplicated discovery, and the unsafe Pixel/BLOCKED shortcut; added complete paginated discovery and validation. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$591.32`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=591.32 -->
## Stack Third PR, stacked on #4173 (`fix-chat-loading-gap`), which is stacked on #4172. Merge bottom-up; this diff contains only the concurrency-warning change. ## Summary Replace changing agent names with a stable compact count: **“N other local agents running — may interfere.”** Agent activity handoffs previously switched the selected name and caused random-looking flashes. Names no longer participate in warning rendering. ## Implementation - Subscribe to the active count instead of the first active workspace identity. - Preserve existing brief handoff protection, same-family suppression, and project/runtime isolation rules. Scope the held count to sorted eligible workspace IDs so reordering is harmless and eligibility changes clear stale warnings. - Keep the single-row composer decoration and use tabular numerals for stable count typography. No new timers, effects, animations, or tooltips. - Cover multi-agent handoffs and metadata reordering, with desktop and explicitly pinned phone stories. ## Validation - All 47 warning/Storybook contract tests pass, including 10 warning handoff/filtering cases. - Three Chromium Storybook renders pass: single-agent desktop, multiple-agent desktop, and fixed-390px phone. Phone checks cover overflow, tabular numerals, and composer clearance. - `make static-check` passes on the integrated three-PR stack. ## Subtractive ledger **P1: 27 production lines added, 33 removed; net −6.** Removed selected-agent/name resolution and simplified the ChatPane interface. The existing eligibility and handoff safeguards remain. Tests/stories are excluded; no unrelated offsets. ## Risks The warning now reports quantity rather than identity, including for one other agent. Counts change only with activity/eligibility, not with whichever agent happens to appear first. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$436.55`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=436.55 -->
## Summary Make PR readiness use GitHub's complete check rollup instead of the name-deduplicated `gh pr checks` projection, and record the preference for `gh stack` to manage native stacked PRs. ## Background On #4194, successful `Required` and `Codex Comments` checks from one workflow run hid two still-failing checks with the same names in another run. The previous readiness workflow incorrectly reported success. The new discovery path was tested against that live failure and returns exit 1 with both failing job URLs. ## Implementation - Share paginated, commit-pinned head/merge check discovery between the readiness waiter and log extractor; retain independent suite results while relying on GitHub's rollup to exclude superseded attempts. - Fail closed on API errors or incomplete pagination, and keep unknown check states pending. Revalidate PR refs and merge/review state before accepting collected checks; a concurrent push or base update returns pending. - Do not infer that a pending Pixel status explains GitHub's `BLOCKED` state. Failure output prioritizes failing checks and identifies their commits. - Run offline behavioral regressions in CI and update AGENTS.md plus its generated skill copy. ## Stack Remains directly above #4194 in native stack #4174; #4172 and #4173 have merged. ## Validation - 22 new PR-check regressions and 12 existing Codex-gate tests passed. - Shellcheck, `make static-check`, and `git diff --check` passed. - Live reproduction on #4194 surfaced both hidden failures from run `34385271008`; retrying that exact run subsequently passed. ## Risks Readiness becomes intentionally stricter: independent failures and unexplained GitHub blockers can no longer be masked by same-name successes or optional Pixel statuses. ## Production ledger Workflow scripts/config: +125 / −51 (net +74), excluding tests and documentation. Removed repeated state predicates, duplicated discovery, and the unsafe Pixel/BLOCKED shortcut; added complete paginated discovery and validation. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$591.32`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=591.32 -->
## Summary Record the user preference to use `gh stack` for GitHub-native stacked PRs, keeping every PR linked in the native stack rather than only chaining base branches. `AGENTS.md` points to `docs/AGENTS.md`; the generated built-in skill copy is synchronized. ## Stack Fourth PR in native stack #4174, directly above #4194: #4172 → #4173 → #4194 → this PR. Stack membership is managed with `gh stack link`. ## Validation - Formatting checked against the resolved `AGENTS.md` target. - `make static-check` and `git diff --check`. - No prose-only assertion tests added. ## Subtractive ledger Production logic: +0 / −0. One documentation line and its generated string mirror; no behavior changes or unrelated subtractions. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$459.97`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=459.97 -->
## Summary Make PR readiness use GitHub's complete check rollup instead of the name-deduplicated `gh pr checks` projection, and record the preference for `gh stack` to manage native stacked PRs. ## Background On #4194, successful `Required` and `Codex Comments` checks from one workflow run hid two still-failing checks with the same names in another run. The previous readiness workflow incorrectly reported success. The new discovery path was tested against that live failure and returns exit 1 with both failing job URLs. ## Implementation - Share paginated, commit-pinned head/merge check discovery between the readiness waiter and log extractor; retain independent suite results while relying on GitHub's rollup to exclude superseded attempts. - Fail closed on API errors or incomplete pagination, and keep unknown check states pending. - Do not infer that a pending Pixel status explains GitHub's `BLOCKED` state. Failure output prioritizes failing checks and identifies their commits. - Run offline behavioral regressions in CI and update AGENTS.md plus its generated skill copy. ## Stack Remains directly above #4194 in native stack #4174; #4172 and #4173 have merged. ## Validation - 19 new PR-check regressions and 12 existing Codex-gate tests passed. - Shellcheck, `make static-check`, and `git diff --check` passed. - Live reproduction on #4194 surfaced both hidden failures from run `34385271008`; retrying that exact run subsequently passed. ## Risks Readiness becomes intentionally stricter: independent failures and unexplained GitHub blockers can no longer be masked by same-name successes or optional Pixel statuses. ## Production ledger Workflow scripts/config: +100 / −49 (net +51), excluding tests and documentation. Removed repeated state predicates, duplicated discovery, and the unsafe Pixel/BLOCKED shortcut; added complete paginated discovery and validation. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$591.32`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=591.32 -->
## Summary Make PR readiness use GitHub's complete check rollup instead of the name-deduplicated `gh pr checks` projection, and record the preference for `gh stack` to manage native stacked PRs. ## Background On #4194, successful `Required` and `Codex Comments` checks from one workflow run hid two still-failing checks with the same names in another run. The previous readiness workflow incorrectly reported success. The new discovery path was tested against that live failure and returns exit 1 with both failing job URLs. ## Implementation - Share paginated, commit-pinned head/merge check discovery between the readiness waiter and log extractor; retain independent suite results while relying on GitHub's rollup to exclude superseded attempts. - Fail closed on API errors or incomplete pagination, and keep unknown check states pending. Revalidate PR refs and merge/review state before accepting collected checks; a concurrent push or base update returns pending. - Do not infer that a pending Pixel status explains GitHub's `BLOCKED` state. Failure output prioritizes failing checks and identifies their commits. - Run offline behavioral regressions in CI and update AGENTS.md plus its generated skill copy. ## Stack Remains directly above #4194 in native stack #4174; #4172 and #4173 have merged. ## Validation - 22 new PR-check regressions and 12 existing Codex-gate tests passed. - Shellcheck, `make static-check`, and `git diff --check` passed. - Live reproduction on #4194 surfaced both hidden failures from run `34385271008`; retrying that exact run subsequently passed. ## Risks Readiness becomes intentionally stricter: independent failures and unexplained GitHub blockers can no longer be masked by same-name successes or optional Pixel statuses. ## Production ledger Workflow scripts/config: +125 / −51 (net +74), excluding tests and documentation. Removed repeated state predicates, duplicated discovery, and the unsafe Pixel/BLOCKED shortcut; added complete paginated discovery and validation. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$591.32`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=591.32 -->
…4196) ## Summary Make PR readiness use GitHub's complete check rollup instead of the name-deduplicated `gh pr checks` projection, and record the preference for `gh stack` to manage native stacked PRs. ## Background On #4194, successful `Required` and `Codex Comments` checks from one workflow run hid two still-failing checks with the same names in another run. The previous readiness workflow incorrectly reported success. The new discovery path was tested against that live failure and returns exit 1 with both failing job URLs. ## Implementation - Share paginated, commit-pinned head/merge check discovery between the readiness waiter and log extractor; retain independent suite results while relying on GitHub's rollup to exclude superseded attempts. - Fail closed on API errors or incomplete pagination, and keep unknown check states pending. Revalidate PR refs and merge/review state before accepting collected checks; a concurrent push or base update returns pending. - Do not infer that a pending Pixel status explains GitHub's `BLOCKED` state. Failure output prioritizes failing checks and identifies their commits. - Run offline behavioral regressions in CI and update AGENTS.md plus its generated skill copy. ## Stack Only remaining open PR in native stack #4174, now based on main after #4172, #4173, and #4194 merged. ## Validation - 22 new PR-check regressions and 12 existing Codex-gate tests passed. - Shellcheck, `make static-check`, and `git diff --check` passed. - Live reproduction on #4194 surfaced both hidden failures from run `34385271008`; retrying that exact run subsequently passed. ## Risks Readiness becomes intentionally stricter: independent failures and unexplained GitHub blockers can no longer be masked by same-name successes or optional Pixel statuses. ## Production ledger Workflow scripts/config: +125 / −51 (net +74), excluding tests and documentation. Removed repeated state predicates, duplicated discovery, and the unsafe Pixel/BLOCKED shortcut; added complete paginated discovery and validation. --- _Generated with `xum` • Model: `openai:gpt-6-astra` • Thinking: `xhigh` • Cost: `$591.32`_ <!-- mux-attribution: model=openai:gpt-6-astra thinking=xhigh costs=591.32 -->
Summary
Keep stopped sub-agents stopped across application restart and chat replay, preventing false startup activity and local-concurrency warning flashes. This is the lower PR in a stack; #4173 contains the loading-UI cleanup.
Implementation
Validation
make static-checkpasses.Subtractive ledger
P1: 553 production lines added, 556 removed; net −3. Removed the duplicate child recovery path and child-only option precedence, shared the existing read-retry loop and interrupted-tail predicate, reused existing error/model/agent-ID normalization, and shared read plumbing, send settings, and log context without dropping diagnostics; shared per-ID guidance settlement replaces duplicated batch/live cleanup. These retain safety checks while reducing competing recovery paths; no new persisted state. Tests are excluded.
Risks
Startup ownership changes across chat replay and task reconciliation. Admission conservatively preserves Stop/question state when disk reads remain unavailable; explicit resume and live retry remain covered by the service suites.
Pains
Review exposed legacy task states and workflow/recovery interactions, requiring additional disk-backed regressions. Existing retry timing is virtualized in persistent-error tests to keep validation deterministic.
Generated with
xum• Model:openai:gpt-6-astra• Thinking:xhigh• Cost:$406.76