Repository navigation
Conversation
Track last bootstrap/refresh error, expose when remote pricing is enabled in health/status JSON, health CLI, and status overview when degraded. Co-authored-by: Cursor <[email protected]>
|
Thanks for the context here. I swept through the related work, and this is now duplicate or superseded. This PR is superseded by the merged current-main fix in #80277, which implements the same model-pricing health/status behavior with gateway-owned state and broader status coverage; the remaining branch is incomplete and should not be merged. So I’m closing this here and keeping the remaining discussion on the canonical linked item. Review detailsBest possible solution: Keep the merged gateway-owned health implementation from #80277 and close this branch instead of trying to rework the superseded diff. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection and current-main regression tests give a high-confidence path: force model-pricing catalog fetch failure and verify health/status surfaces report Is this the best way to solve the issue? No for this PR branch. The merged current-main implementation is the better solution because it stores failures in gateway-owned pricing cache state and renders gateway probe health through health, status, status JSON, and gateway status. Security review: Security review cleared: The diff is limited to process-local diagnostic state and additive health/status fields, with no dependency, workflow, secret-handling, or code-execution surface changes. What I checked:
Likely related people:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 7d2a8677c722; fix evidence: commit fa2b97da4ace, main fix timestamp 2026-05-10T15:27:07+01:00. |
[P1] Restore deleted getStatusSummary import that was still used in status handler [P2] Record catalog fetch failures for both OpenRouter and LiteLLM in the Promise.all catch blocks, so failures are tracked in the bootstrap health ledger [P2] LiteLLM failure recording was missing entirely — add it Fixes ClawSweeper review findings for PR #79914
Summary
modelPricinginhealth+statusJSON when remote pricing bootstrap is enabled; CLIhealthprintsModel pricing: degraded (...); textstatusoverview gains a degraded row when degraded.Fixes #79599
Test plan
pnpm exec vitest run src/gateway/model-pricing-cache.test.tsReal behavior proof
openclaw gateway; provoke cold-start CDN failure (curlegress block or bogusHTTPS_PROXY); callopenclaw health,openclaw health --json,openclaw status,openclaw status --json; restore egress and observe recovery window.state: okafter successful refresh clears failure ledger.(Supplemental) Automated/unit:
pnpm exec vitest run src/gateway/model-pricing-cache.test.ts.