Skip to content

Use Claude Code, Codex, VSCode, Pi, and OpenCode (and 6 other harnesses) for free (1.3B+ free tokens) from your terminal, app, IDE, or phone, and now from the browser with native browser sessions (multi-harness + multi-model) like OpenClaw (voice supported + ToS friendly)

Python

Fix Grok compatibility detection (#1597)

Ali Khokhar2600db950ac2
diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md
index 904cbe98..349b2eb4 100644
--- a/ARCHITECTURE.md
+++ b/ARCHITECTURE.md
@@ -1471,7 +1471,7 @@ own the installed `fcc-dsh` launcher for DeepSeek Harness 0.1.0-rc.8:
sandbox.
[cli/launchers/grok.py](src/free_claude_code/cli/launchers/grok.py) owns the
-installed `fcc-grok` launcher for stable Grok Build 1.0.5 or newer:
+installed `fcc-grok` launcher for Grok Build 1.0.5 or newer:
- Attached TUI, headless, and `agent stdio` sessions require a reachable FCC
server, a canonical proxy token, and a non-empty direct Responses catalog.
diff --git a/pyproject.toml b/pyproject.toml
index b12141f7..3d77cd0a 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
[project]
name = "free-claude-code"
-version = "5.15.6"
+version = "5.15.7"
description = "Local proxy connecting coding agents to OpenAI-compatible AI providers"
readme = "README.md"
requires-python = ">=3.14.0"
diff --git a/smoke/features.py b/smoke/features.py
index 26d00f1a..7f423656 100644
--- a/smoke/features.py
+++ b/smoke/features.py
@@ -195,7 +195,7 @@ FEATURE_INVENTORY: tuple[FeatureCoverage, ...] = (
("test_probe_and_models_routes",),
("test_grok_cli_headless_e2e",),
("clients",),
- ("stable Grok Build 1.0.5+",),
+ ("Grok Build 1.0.5+",),
"skip only when Grok Build is absent; the local fake upstream must pass",
),
FeatureCoverage(
diff --git a/src/free_claude_code/cli/launchers/grok.py b/src/free_claude_code/cli/launchers/grok.py
index b2e0f6d9..0a2e3358 100644
--- a/src/free_claude_code/cli/launchers/grok.py
+++ b/src/free_claude_code/cli/launchers/grok.py
@@ -253,7 +253,7 @@ def classify_grok_invocation(argv: Sequence[str]) -> GrokInvocation:
def require_compatible_grok(binary_path: str) -> None:
- """Exit unless Grok Build satisfies FCC's stable custom-model contract."""
+ """Exit unless Grok Build satisfies FCC's custom-model contract."""
version = grok_binary_version(binary_path)
if version is not None and version >= _MINIMUM_VERSION:
@@ -261,8 +261,7 @@ def require_compatible_grok(binary_path: str) -> None:
minimum = ".".join(str(part) for part in _MINIMUM_VERSION)
print(
- f"The Grok Build CLI at {binary_path} must be a stable release at least "
- f"version {minimum}.",
+ f"The Grok Build CLI at {binary_path} must be at least version {minimum}.",
file=sys.stderr,
)
print(_INSTALL_HINT, file=sys.stderr)
@@ -270,7 +269,7 @@ def require_compatible_grok(binary_path: str) -> None:
def grok_binary_version(binary_path: str) -> tuple[int, int, int] | None:
- """Read Grok Build's machine-readable stable release metadata."""
+ """Read Grok Build's machine-readable version metadata."""
try:
result = subprocess.run(
@@ -290,7 +289,7 @@ def grok_binary_version(binary_path: str) -> tuple[int, int, int] | None:
payload: JsonValue = json.loads(result.stdout)
except json.JSONDecodeError:
return None
- if not isinstance(payload, dict) or payload.get("channel") != "stable":
+ if not isinstance(payload, dict):
return None
current_version = payload.get("currentVersion")
diff --git a/tests/cli/test_grok_launcher.py b/tests/cli/test_grok_launcher.py
index 65314fe9..0f565610 100644
--- a/tests/cli/test_grok_launcher.py
+++ b/tests/cli/test_grok_launcher.py
@@ -178,8 +178,9 @@ def test_route_bypass_flags_are_rejected_before_version_probe(argv: list[str]) -
(1, 0, 5),
),
('{"channel":"stable","currentVersion":"1.2.3+build.1"}', 0, (1, 2, 3)),
+ ('{"currentVersion":"1.0.5","channel":"unknown"}', 0, (1, 0, 5)),
+ ('{"currentVersion":"1.2.3","channel":"alpha"}', 0, (1, 2, 3)),
('{"currentVersion":"1.2.3-alpha.1","channel":"stable"}', 0, None),
- ('{"currentVersion":"1.2.3","channel":"preview"}', 0, None),
('{"currentVersion":123,"channel":"stable"}', 0, None),
('{"currentVersion":"1.2.3","channel":"stable"}', 1, None),
('{"currentVersion":"1.2.3\t(build)","channel":"stable"}', 0, None),
diff --git a/uv.lock b/uv.lock
index b5902b64..dccd7eee 100644
--- a/uv.lock
+++ b/uv.lock
@@ -607,7 +607,7 @@ wheels = [
[[package]]
name = "free-claude-code"
-version = "5.15.6"
+version = "5.15.7"
source = { editable = "." }
dependencies = [
{ name = "aiohttp" },