Skip to content

fix(status): show delivery queue warnings in detailed reports - #134889

Merged
steipete merged 2 commits into
mainfrom
codex/upgrade-ingress-status-warnings
Sep 1, 2026
Merged

steipete merged 2 commits into
mainfrom
codex/upgrade-ingress-status-warnings

Conversation

@steipete

@steipete steipete commented Sep 1, 2026 •

Copy link
Copy Markdown
Contributor

Related: #133984

What Problem This Solves

Fixes an issue where status --deep and status --all could show a reachable Gateway and healthy channel while omitting an inbound delivery backlog already present in Gateway health.

Why This Change Was Made

Move the existing delivery-queue formatter into the shared health-format module and use it on all three detailed diagnostic surfaces. Keep the formatter's transport-error dependency light and type the actual health response instead of serializing unknown error shapes.

User Impact

Detailed status reports show pressured ingress lanes and dead-lettered deliveries alongside channel connectivity. Ordinary status gains no extra probe. Queue ordering, retries, retention, and repair behavior remain unchanged.

Evidence

A real isolated baseline Gateway exposed one pressured lane, two pending messages, and one blocked message through health and deep JSON. All five CLI commands exited successfully, but deep/all text omitted the warning. The identical renderer diagnostic failed three assertions before the fix and passed all four afterward. Candidate replay of the same five commands passes: deep/all text now contains the warning and counts, health/deep JSON retain the same pressure, and Gateway shutdown exits 0. The replay uses the combined candidate build; the isolated renderer diagnostic attributes the output correction to this patch.

All 112 focused health/status tests pass. Gateway cleanup completed without remaining task processes. The pressure fixture uses synthetic local state; no Telegram or other channel message was sent.

Production LOC: net -4 after discounting the formatter move. Tests: net +100, including five existing formatter cases moved with their owner; docs: +5. The existing eight-attempt and 24-hour ingress policy is intentional and unchanged; this fixes visibility rather than the unconfirmed producer of the reported stalled turn.

Independent Codex autoreview found no actionable findings. The refactor also removes the obsolete one-assertion allowance from the assertion-safety baseline. The actual changed gate passed all 30 selected checks, including core and core-test types, core and tooling lint, import cycles, and remaining guards.

The first hosted CI run exposed an old Doctor test that forced the transport-error guard to accept an ordinary error. The fixture now constructs the real GatewayTransportError, removes the obsolete facade mock, and keeps the sanitized diagnostic assertion. This correction changes tests only. Formatting, typed lint, core-test types, all 35 formatter tests, and a direct real-error/formatter diagnostic pass; independent Codex review is clean. The full local Doctor run reached the runner's existing no-output limit before assertions and is recorded as incomplete. Hosted CI on e55f374 subsequently passed the corrected Doctor case, its restart sibling, and the entire Doctor group (5 files, 171 tests).

The latest ClawSweeper review has no code findings and asks for completed exact-head CI and ordinary maintainer handling. Its automated stored-data-model warning does not apply: diagnosis.ts only projects an existing HealthSummary into report text. This PR has no schema, stored-state, migration, retention, or recovery change.

The prior remaining hosted failure was the shared release-inventory git ls-tree output overflow. This branch is rebased onto the canonical repair in #134824 (eaaa6da); both PR commits remain patch-identical. Full CI on rebased head f6b824f8b4d passed: 222 successful checks, one neutral result, 45 skips, and none pending or failing. This satisfies the latest ClawSweeper rank-up request for green exact-head CI. No status or health assertion failed on the corrected pre-rebase head.

@steipete steipete self-assigned this Sep 1, 2026
@clawsweeper

clawsweeper Bot commented Sep 1, 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 commands Command implementations size: M maintainer Maintainer-authored PR labels Sep 1, 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 1, 2026
@clawsweeper

clawsweeper Bot commented Sep 1, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 1, 2026, 2:24 AM ET / 06:24 UTC.

ClawSweeper review

What this changes

This PR moves existing delivery-queue formatting into a shared CLI formatter and displays dead-letter and inbound-pressure warnings in status --deep and status --all.

Regression provenance

Possible regression — probable (reviewed change; failure trace). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

Keep open for normal maintainer handling. Current main still omits these already-produced warnings, while the branch adds them to both detailed report paths with focused coverage; no blocking correctness or security finding was identified. Exact-head CI is still incomplete.

Priority: P2
Reviewed head: e55f374c183a95976da6cc72f23d3e89b6dbfbfd

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The source-level repair is focused, net-negative in production code, and covered at formatter and renderer boundaries; exact-head CI remains the outstanding merge gate.
Proof confidence 🌊 off-meta tidepool Not applicable: This member-authored PR is exempt from the external-contributor proof gate; its body nevertheless records an isolated Gateway replay that maps existing health counters to the changed detailed CLI renderers.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This member-authored PR is exempt from the external-contributor proof gate; its body nevertheless records an isolated Gateway replay that maps existing health counters to the changed detailed CLI renderers.
Evidence reviewed 7 items Current-main gap: The fetched main revision renders only channel-health lines in the standard Health table, so queue warnings already present in the health snapshot are omitted.
Health producer and PR consumer: Gateway health attaches delivery-queue data when present; the branch formats that existing data and appends it as a warning row without changing queue policy or persistence.
Both detailed report paths: The standard status report passes its deep health snapshot into the table builder, and the complete report resolves safe health before passing it to diagnosis; the PR consumes the successful snapshot in each renderer.
Findings None None.
Security None None.

How this fits together

Gateway health produces bounded delivery-queue counters alongside channel health. Detailed status commands consume that snapshot and render operator-facing tables or diagnostic text.

flowchart LR
A[Gateway health snapshot] --> B[Delivery queue counters]
B --> C[Shared CLI formatter]
C --> D[Deep status health table]
C --> E[Complete status diagnosis]
D --> F[Operator warning]
E --> F
Loading

Before merge

  • Resolve merge risk (P1) - Exact-head CI is incomplete, so targeted source and contributor-provided replay evidence do not yet establish merge readiness.
  • Complete next step (P2) - No repair task is indicated: the remaining action is completion of exact-head CI followed by ordinary maintainer handling.
Agent review details

Security

None.

PR surface

Source -4, Tests +100, Docs +5, Other -1. Total +100 across 11 files.

View PR surface stats
Area Files Added Removed Net
Source 4 72 76 -4
Tests 5 195 95 +100
Docs 1 5 0 +5
Config 0 0 0 0
Generated 0 0 0 0
Other 1 0 1 -1
Total 11 272 172 +100

Review metrics

Metric Value Why it matters
Production versus test LOC production +72/-76 (net -4); tests +195/-95 (net +100); docs +5; baseline -1 The production change is a net-negative formatter relocation plus two render consumers; added tests cover the newly visible detailed-report paths.

Stored data model

Persistent data-model change detected: serialized state: src/commands/status-all/diagnosis.ts, unknown-data-model-change: src/commands/status-all/diagnosis.ts. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Complete exact-head CI and retain this focused shared-rendering fix, which exposes the health data without changing queue behavior.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Complete exact-head CI and retain this focused shared-rendering fix, which exposes the health data without changing queue behavior.

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

Yes—source inspection shows Gateway health already produces delivery-queue counters while fetched main renders only channel health in detailed status output. The PR adds the missing render consumers and focused regression coverage.

Is this the best way to solve the issue?

Yes—the shared formatter keeps existing health semantics canonical and feeds the two omitted detailed renderers rather than duplicating queue inspection or modifying delivery policy.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 1d54f21d0368.

Labels

Label justifications:

  • P2: This repairs operator visibility for existing delivery backlogs without changing delivery, retries, or persisted state.
  • 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 member-authored PR is exempt from the external-contributor proof gate; its body nevertheless records an isolated Gateway replay that maps existing health counters to the changed detailed CLI renderers.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • vincentkoc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Wait for the required exact-head CI matrix to complete successfully before merging.

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.

History

Review history (1 earlier review cycle)
  • reviewed 2026-09-01T05:48:19.080Z sha 0695274269b3e7f25fa7e18eaae44aa166b39cfe :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the codex/upgrade-ingress-status-warnings branch from e55f374 to f6b824f Compare September 1, 2026 06:41
@steipete
steipete merged commit 437ef61 into main Sep 1, 2026
280 checks passed
@steipete
steipete deleted the codex/upgrade-ingress-status-warnings branch September 1, 2026 06:55
@steipete

steipete commented Sep 1, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 2, 2026
…aw#134889)

* fix(status): show delivery queue warnings in detailed reports

* test(doctor): use the real gateway transport error fixture
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

commands Command implementations docs Improvements or additions to documentation 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: M 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