Skip to content

fix(xai): bump Grok CLI compatibility version to 1.0.22 (426 outdated) - #6339

Closed
unsafe9 wants to merge 1 commit into
lidge-jun:devfrom
unsafe9:fix/xai-grok-client-version
Closed

unsafe9 wants to merge 1 commit into
lidge-jun:devfrom
unsafe9:fix/xai-grok-client-version

Conversation

@unsafe9

@unsafe9 unsafe9 commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Problem

xAI now rejects Grok CLI OAuth requests that report a client version below 1.0.13:

426 "Your Grok CLI version (0.2.93) is outdated. Please update to version 1.0.13 or later"

OpenCodex hardcodes 0.2.93 in XAI_GROK_COMPATIBILITY, sent as x-grok-client-version and in the User-Agent on the OAuth (SuperGrok) path, so every Grok OAuth request fails regardless of the locally installed grok CLI.

Change

Bump XAI_GROK_COMPATIBILITY.version / userAgent to 1.0.22 (current Grok CLI). Both constants derive from this single source; no other 0.2.93 references exist in src or tests.

Verification

bun test on the 5 test files referencing xai-transport / XAI_GROK: 175 pass, 0 fail. Not verified against live xAI.

Review readiness checklist

This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:

  • Required local validation passed; commands, results, and any full-suite exception are documented.

  • I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).

  • I resolved all correct Codex and CodeRabbit findings.

  • My PR is ready for review.

Summary by CodeRabbit

  • Chores
    • Updated the reported Grok compatibility version and user agent.

@github-actions github-actions Bot added the intake: hygiene-blocked Deterministic PR hygiene checks failed label Oct 1, 2026
@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

⚠️ Deterministic hygiene checks failed.

  • missing_regression_test — Behavior changed under src/ or gui/src/ without a test change. Add focused coverage or obtain test-exception-approved.

@github-actions github-actions Bot added the bug Something isn't working label Oct 1, 2026
@github-actions

github-actions Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

⏳ DRAFT

  • hygiene: missing_regression_test.

What to do

  • Fix missing_regression_test — Behavior changed under src/ or gui/src/ without a test change. Add focused coverage or obtain test-exception-approved.
  • Tick all four boxes in the PR description once you're done (currently 0/4).

Review readiness checklist

  • ⬜ Required local validation passed; commands, results, and any full-suite exception are documented.
  • ⬜ I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).
  • ⬜ I resolved all correct Codex and CodeRabbit findings.
  • ⬜ My PR is ready for review.

0/4 boxes ticked.

This pull request was already a draft. Its draft status will be preserved after every issue above is resolved.
@unsafe9 Tick the boxes once required local validation has passed with commands, results, and any full-suite exception documented, your branch is on the latest dev commit, and every correct Codex and CodeRabbit finding is resolved.

@github-actions
github-actions Bot marked this pull request as draft October 1, 2026 00:44
@coderabbitai

coderabbitai Bot commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Note

Repository guideline files applied to this review (1)
src/AGENTS.md — auto-discovered

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: lidge-jun/opencodex/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 2382e7de-99c0-4464-8092-e9af2b29589c

📥 Commits

Reviewing files that changed from the base of the PR and between 349588e and 60e90bb.

📒 Files selected for processing (1)
  • src/providers/xai-transport.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.


📝 Walkthrough

Walkthrough

The Grok compatibility version and user-agent version change from 0.2.93 to 1.0.22.

Changes

Grok compatibility version

Layer / File(s) Summary
Update compatibility metadata
src/providers/xai-transport.ts
The compatibility version and user-agent version change from 0.2.93 to 1.0.22.

Priority: ➖ Normal

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Bug fix

Suggested reviewers: lidge-jun

Merge Risk: ⚪ Minimal · up to 60e90

The change updates Grok compatibility metadata without changing request behavior. No actionable merge-blocking issue is established. Live xAI acceptance was not tested.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the xAI compatibility fix and the version bump to 1.0.22, which matches the main change in src/providers/xai-transport.ts. The parenthetical text is unnecessary but does n…
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 1 files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

lidge-jun added a commit that referenced this pull request Oct 1, 2026
* fix(xai): report a current Grok CLI version on the OAuth path

xAI now answers Grok OAuth requests that report a client version below 1.0.13 with HTTP 426 ("Your Grok CLI version (0.2.93) is outdated"), so every SuperGrok OAuth request failed. Report 1.0.25, the current stable Grok CLI, in x-grok-client-version and the User-Agent.

Carries #6339.

Co-authored-by: unsafe9 <24631203+unsafe9@users.noreply.github.com>

* test(xai): pin Grok compatibility header regression

---------

Co-authored-by: unsafe9 <24631203+unsafe9@users.noreply.github.com>
@lidge-jun

Copy link
Copy Markdown
Owner

Landed on dev through maintainer PR #6341 with a Co-authored-by trailer for you. It reports the current stable Grok CLI (1.0.25) instead of 1.0.22 and pins the header test to a literal value, since the old snapshot derived its expectation from the constant and could not catch a revert. Thanks for catching the 426!

@lidge-jun lidge-jun closed this Oct 1, 2026
wongang2 pushed a commit to wongang2/opencodex that referenced this pull request Oct 2, 2026
…jun#6341)

* fix(xai): report a current Grok CLI version on the OAuth path

xAI now answers Grok OAuth requests that report a client version below 1.0.13 with HTTP 426 ("Your Grok CLI version (0.2.93) is outdated"), so every SuperGrok OAuth request failed. Report 1.0.25, the current stable Grok CLI, in x-grok-client-version and the User-Agent.

Carries lidge-jun#6339.

Co-authored-by: unsafe9 <24631203+unsafe9@users.noreply.github.com>

* test(xai): pin Grok compatibility header regression

---------

Co-authored-by: unsafe9 <24631203+unsafe9@users.noreply.github.com>
(cherry picked from commit 6f2f6ae)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working intake: hygiene-blocked Deterministic PR hygiene checks failed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants