test(live): classify xAI degraded availability#107887
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8d8cc2e80c
ℹ️ 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".
| const msg = normalizeLowercaseStringOrEmpty(raw); | ||
| return ( | ||
| isOverloadedErrorMessage(raw) || | ||
| isServerErrorMessage(raw) || |
There was a problem hiding this comment.
Guard 4xx server_error payloads before skipping
When a provider returns a 4xx OpenAI-compatible error whose body still contains server_error (for example 422 ... {"error":{"type":"server_error"}}), this new branch makes shouldSkipLiveProviderDrift({ allowProviderUnavailable: true }) classify it as a provider outage. Existing failover coverage keeps explicit 4xx statuses ahead of server_error markers in src/agents/failover-error.test.ts:1264-1270, so live lanes that enable provider-unavailable skips can now hide request/auth/billing regressions instead of failing them.
Useful? React with 👍 / 👎.
|
Land-ready proof for exact head
Best-fix verdict: yes. The patch centralizes temporary provider-unavailability recognition, preserves unknown-error failures, and keeps xAI request, response, content, and citation assertions deterministic. |
|
Merged via squash.
|
What Problem This Solves
Full Release Validation failed the native xAI agent lane when Grok returned
Service temporarily unavailable. The model's availability is currently degraded.One live tool-call assertion failed while 74 sibling native live tests passed; fail-fast then cancelled unrelated Docker, package, QA, and cross-OS work.Failure: https://github.com/openclaw/openclaw/actions/runs/29379189220/job/87239480734
Why This Change Was Made
Route xAI live-test drift through the existing canonical live-provider classifier. Extend that classifier to consume the already-established overload and server-error matchers, including the exact observed xAI degradation response. Use the same classifier for returned web-search errors, not only thrown completion errors.
This does not relax tool payload, assistant text, citation, or provider assertions. Only recognized billing/upstream availability failures are skipped. xAI's official debugging guidance distinguishes service errors from request errors and directs ongoing disruptions to its status service: https://docs.x.ai/developers/debugging
User Impact
No runtime behavior change. Live release validation no longer treats a recognized temporary provider outage as an OpenClaw contract regression; deterministic response and payload regressions still fail.
Evidence
tbx_01kxhmp3faved74m07bxgtrtmhgit diff --checkpassedAfter PR CI, rerun
native-live-src-agentson this exact head, then rerun Full Release Validation on the landed main SHA.No changelog entry: test/release-harness robustness only.