Skip to content

fix(xai): Grok subscription inference fails with HTTP 426 on every request - #117704

Closed
clawsweeper[bot] wants to merge 1 commit into
mainfrom
clawsweeper/automerge-openclaw-openclaw-113663
Closed

clawsweeper[bot] wants to merge 1 commit into
mainfrom
clawsweeper/automerge-openclaw-openclaw-113663

Conversation

@clawsweeper

@clawsweeper clawsweeper Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

Makes #113663 merge-ready for the ClawSweeper automerge loop.
The edit pass should inspect the live PR diff, review comments, and failing checks; rebase if needed; keep the contributor branch credited; and stop only when validation is green or an external blocker is proven.

Source

Replacement for #113663 because the source branch could not be updated.

Inherited issue-closing references from the source PR:
Closes #113662

Original contributor: @jzakirov.

@clawsweeper clawsweeper Bot added clawsweeper:automerge Maintainer opted this PR into bounded ClawSweeper-reviewed automerge extensions: xai clawsweeper Tracked by ClawSweeper automation labels Aug 2, 2026
@clawsweeper clawsweeper Bot added rating: 🌊 off-meta tidepool PR readiness rating does not apply to this item. status: 🚀 automerge armed This PR is in ClawSweeper's automerge lane. P1 High-priority user-facing bug, regression, or broken workflow. labels Aug 2, 2026
@clawsweeper

clawsweeper Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the context here. I did a careful shell check against current main, and this is already implemented.

Close this replacement PR: current main already fixes the actual outbound Grok OAuth inference path, so the new provider-catalog header would duplicate behavior now owned by the xAI stream wrapper. The main-branch repair is newer than v2026.7.1 and has not been proven shipped in a release tag yet.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #113662
Summary: This replacement PR targets the same xAI OAuth inference incident as the canonical report, but current main independently implements the needed outbound-header behavior.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

So I’m closing this as already implemented rather than keeping a duplicate issue open.

Review details

Best possible solution:

Keep the proxy-specific request contract in the existing xAI stream wrapper and avoid a second provider-catalog header path.

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

No high-confidence current-main failure remains: the actual outbound stream path now writes the required header for the canonical Grok OAuth proxy, and extensions/xai/stream.test.ts:151 asserts that contract.

Is this the best way to solve the issue?

No; the branch fixes a catalog-layer symptom, while current main fixes the actual outbound stream owner and also scopes the complete Grok proxy header contract away from API-key traffic.

Security review:

Security review cleared: The proposed change adds no dependency, secret, workflow, or privilege surface; its vendor header is non-secret and current main already scopes the complete proxy contract to the canonical endpoint.

AGENTS.md: found and applied where relevant.

What I checked:

  • Current-main implementation: The xAI stream wrapper detects the canonical Grok OAuth proxy and writes X-XAI-Token-Auth, x-grok-client-version, and x-grok-model-override immediately before calling the underlying inference stream. (extensions/xai/stream.ts:29, e9bd45d38d4f)
  • Runtime hookup: The xAI plugin installs that wrapper for provider streams and supplies the running OpenClaw version as the required client-version value. (extensions/xai/index.ts:257, e9bd45d38d4f)
  • Regression coverage: Current main has a focused stream-wrapper test asserting that a Grok OAuth model receives the client-version header and that the public API-key route does not. (extensions/xai/stream.test.ts:151, e9bd45d38d4f)
  • Fix provenance: Blame and header-history both attribute the current implementation to this commit on main, dated 2026-08-01T13:25:29-07:00. (extensions/xai/stream.ts:43, e9bd45d38d4f)
  • Release/main-only check: The repair commit is an ancestor of current main but not of the latest supplied release tag v2026.7.1; this is current-main-only provenance. (extensions/xai/stream.ts:43, e9bd45d38d4f)

Likely related people:

  • Peter Steinberger: Current main attributes both the OAuth request-header wrapper and its plugin entrypoint hookup to the same recent commit. (role: recent area contributor; confidence: high; commits: e9bd45d38d4f; files: extensions/xai/stream.ts, extensions/xai/index.ts, extensions/xai/stream.test.ts)

Codex review notes: model internal, reasoning high; reviewed against 57a3bf423249; fix evidence: commit e9bd45d38d4f, main fix timestamp 2026-08-01T13:25:29-07:00.

@clawsweeper

clawsweeper Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

ClawSweeper applied the proposed close for this PR.

@clawsweeper clawsweeper Bot closed this Aug 2, 2026
@clawsweeper

clawsweeper Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor Author

🦞👀
ClawSweeper could not autoclose this item.

Reason: structured ClawSweeper close marker: close-required (sha=6e1e9c5f04b60d9f08312edc0de1f23dd693a728)

Usage: /autoclose <maintainer close reason>. I will close this item and any open same-repo items explicitly referenced in the command text.

@RomneyDa
RomneyDa deleted the clawsweeper/automerge-openclaw-openclaw-113663 branch October 22, 2026 00:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clawsweeper:automerge Maintainer opted this PR into bounded ClawSweeper-reviewed automerge clawsweeper Tracked by ClawSweeper automation extensions: xai P1 High-priority user-facing bug, regression, or broken workflow. rating: 🌊 off-meta tidepool PR readiness rating does not apply to this item. size: S status: 🚀 automerge armed This PR is in ClawSweeper's automerge lane.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: xAI OAuth (Grok subscription) inference always fails with HTTP 426 — no Grok CLI client-version header sent to cli-chat-proxy.grok.com

0 participants