Repository navigation
[Bug]: account-unentitled gpt-5.6-sol/terra/luna are advertised as native models and relayed as 502 stream errors #2548
Description
Client or integration
Claude Code
Area
Catalog / models
Summary
The static native catalog advertises gpt-5.6-sol, gpt-5.6-terra, and gpt-5.6-luna as selectable native OpenAI rows regardless of what the authenticated ChatGPT account's own model roster supports. On a free ChatGPT plan every request for these models is forwarded and rejected upstream with:
The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account.
OpenCodex relays this as a 502 (upstream_server_error), which Claude Code surfaces as 502 upstream stream ended before a terminal frame (truncated response) and then retries 10 times. The user-visible symptom blames the stream/truncation, while the real cause is an entitlement gap: the picker offers models the account cannot use.
This is the same class as #2097, which added per-account roster gating for gpt-daybreak-blue-latest (ACCOUNT_GATED_NATIVE_OPENAI_MODELS). That gate currently contains only Daybreak; the GPT-5.6 family needs the same treatment (they are absent from a free account's authenticated /models roster).
Expected: account-gated native models are only advertised (Claude gateway discovery, Codex catalog, management rows) and routed when the authenticated account's roster confirms them; otherwise they are hidden or fail closed before dispatch.
Reproduction
- Log in with a free ChatGPT account (
codex login);ocx provider test openaireports connected (forward auth). - Launch Claude Code through the proxy:
ocx claude --model claude-ocx-native--gpt-5.6-sol. - Send any prompt.
- Observe the retry loop:
✻ 502 upstream stream ended before a terminal frame (truncated response) · Retrying in 2s · attempt 4/10. - Check
~/.opencodex/usage.jsonl: each attempt recordsstatus: 502,errorCode: upstream_server_error,upstreamError: The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account. ocx account refresh openaishows the account plan isfree.
Consistently reproducible. gpt-5.6-luna and gpt-5.6-terra are expected to behave the same (all three ship in the static native list and none appear in a free account's roster).
Version
2.32.1
Operating system
Ubuntu 24.04 (WSL2)
Provider and model
openai (ChatGPT login, authMode: forward, codexAccountMode: direct) / gpt-5.6-sol (also expect gpt-5.6-terra, gpt-5.6-luna)
Logs or error output
$ tail -n 40 ~/.opencodex/usage.jsonl | jq -r 'select(.surface=="claude") | [.status,.provider,.requestedModel,.errorCode,.upstreamError] | @tsv'
502 openai gpt-5.6-sol upstream_server_error The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account.
502 openai gpt-5.6-sol upstream_server_error The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account.
502 openai gpt-5.6-sol upstream_server_error The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account.
...repeats for every retry attemptClaude Code side:
✻ 502 upstream stream ended before a terminal frame (truncated response) · Retrying in 2s · attempt 4/10
Redacted configuration
{
"providers": {
"openai": {
"adapter": "openai-responses",
"baseUrl": "https://chatgpt.com/backend-api/codex",
"authMode": "forward",
"codexAccountMode": "direct"
}
}
}Suggested fix direction
Extend the #2097 mechanism: add gpt-5.6-sol, gpt-5.6-terra, and gpt-5.6-luna to ACCOUNT_GATED_NATIVE_OPENAI_MODELS (src/codex/catalog/native-models.ts) so catalog generation, Claude gateway discovery, management rows, and Pool/Direct routing all require the authenticated per-account /models roster before advertising or dispatching them. I have a local patch along these lines (with updated tests across entitlement/catalog/convergence/auth suites) and can open a PR after review.
Checks
- I searched existing issues and documentation.
- I removed secrets, tokens, account details, request credentials, and personal data.
Activity
lidge-jun commentedon Aug 25, 2026
리뷰 · 우선순위 58 / 80
설명: 이 이슈는 공짜 챗지피티 계정으로 네이티브 모델 gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna 를 고르면, 업스트림이 그 모델을 이 계정에서 쓸 수 없다고 거절하고, 프록시가 그걸 502 스트림 끊김으로 다시 보내는 일이다. 클로드 코드는 응답이 잘렸다고 보고 열 번 다시 보낸다. 작성자는 mushikingh 이다. 클라이언트는 클로드 코드다. 운영체제는 우분투 24.04 WSL2 다. 보고 버전은 2.32.1 이다. 라벨은 bug, account-pool, catalog, streaming 이다. 지금 CURRENT dev HEAD 는 e1fb675 이다. 이번 시간에 origin/dev 가 2549 한 번 착지했다. api-usage 시험이 움직이는 오버레이 버전 숫자를 바로 읽지 않게 고친 일이다. 패키지 글자가 2.32.0 에서 2.32.1-preview.20260825 로 바뀌었다. 이 이슈와 무관하다. 구현 풀은 2550 이다. 드래프트다. 이슈를 연다. 닫지 말 것. 라벨은 바꾸지 말 것. 내가 머지하지 않는다.
HEAD 의 정적 네이티브 목록은 src/codex/catalog/native-models.ts 66-70줄 NATIVE_OPENAI_MODELS 다. gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna 가 그냥 들어 있다. 계정마다 막을 집합 ACCOUNT_GATED_NATIVE_OPENAI_MODELS 는 5-7줄이고, 지금은 gpt-daybreak-blue-latest 하나뿐이다. 카탈로그가 그 집합만 본다. src/codex/catalog/metadata.ts 414-426줄 nativeModelRows 는 게이트된 아이디를 cachedAvailableAccountGatedNativeModels 가 확인한 뒤에만 넣는다. 솔 테라 루나는 그 집합에 없으니 확인 없이 고를 수 있다. 클로드 게이트웨이와 관리 화면 줄도 같은 목록을 쓴다.
라우팅도 같다. src/codex/model-entitlements.ts 270-276줄 isDirectCallerEntitledToCodexModel 은 집합에 없으면 바로 true 를 돌려준다. 287-291줄 entitledCodexAccountIdsForModel 도 집합에 없으면 undefined 라서 계정 고르기를 건너뛴다. 그래서 공짜 계정의 인증된 /models 명단에 없어도 요청이 나간다. 업스트림은 The 'gpt-5.6-sol' model is not supported when using Codex with a ChatGPT account. 를 내고, 프록시는 502 upstream_server_error 로 옮긴다. 클로드 코드는 스트림이 끝 프레임 전에 끊겼다고 보고 다시 보낸다. 본문 usage.jsonl 이 그 502 를 시도마다 적는다.
이 구멍은 2097 과 같은 종류다. 2097 은 데이브레이크만 게이트에 넣었다. 본문이 그 길을 솔 테라 루나에 그대로 쓰자고 적는다. 2550 이 그 세 아이디를 집합에 넣는 드래프트다. 생산 코드는 집합 세 줄이다. 새 라우팅 함수는 없다. 체크리스트 네 칸이 비어 있다. 2550 이 합쳐지기 전에 이 이슈를 닫지 말 것. 보고 버전 2.32.1 은 이미 나온 안정 버전이다. HEAD 에도 게이트가 아직 없다. 재현은 지금 트리에서도 맞다.
src/codex/catalog/native-models.ts 21-23줄 NATIVE_OPENAI_CAPABILITY_SOURCES 는 데이브레이크 능력 글을 gpt-5.6-sol 에서 빌려 온다. 그건 메타데이터 상속이다. 노출과 다르다. 솔을 게이트에 넣어도 그 상속을 바꿀 일은 없다. 이번 시간 2549 는 시험만 고쳤다. 2551 은 preview 로 올린 일이다. 둘 다 이 이슈를 고치지 않는다. 2513 은 구글 서명 드래프트다. 서로 닫지 말 것. 2463 2464 2465 를 닫지 말 것. types.ts 와 config.ts 가르기와는 무관하다. 프리뷰 배포가 아니다.
src/codex/catalog/native-models.ts 5-7줄 HEAD- 게이트 집합에 데이브레이크만 있다. 솔 테라 루나는 없다src/codex/catalog/native-models.ts 66-70줄 HEAD- 정적 네이티브 목록에 솔 테라 루나가 그대로 들어 있다src/codex/catalog/metadata.ts 414-426줄 HEAD- nativeModelRows 가 게이트 집합만 명단 확인 뒤에 넣는다. 집합 밖은 그냥 보인다src/codex/model-entitlements.ts 270-276줄 HEAD- 집합에 없으면 다이렉트 자격이 바로 true 다. 공짜 계정도 요청이 나간다src/codex/model-entitlements.ts 287-291줄 HEAD- 집합에 없으면 계정 고르기를 건너뛴다이슈 본문 Version 2.32.1 - 보고 버전이 이미 나온 안정 버전이다. HEAD 에도 게이트가 없다
2550 - 구현 풀이다. 드래프트다. 체크리스트가 비어 있다. 이 이슈를 그 풀로 지금 닫지 말 것
2097 - 같은 종류의 데이브레이크 게이트다. 그 이슈로 이 이슈를 중복 닫지 말 것
2513 - 구글 서명 드래프트다. 이 이슈와 서로 닫지 말 것
메인테이너의 판단이 필요한 지점
너의 추천
기다린다. 이 이슈는 연다. 2550 이 레디가 되고 합쳐진 뒤에 닫는다. 공짜 계정에서 솔 테라 루나를 카탈로그와 클로드 고르기와 다이렉트와 풀에서 숨기는 길이 맞다. 내가 머지하지 않고 구현하지 않는다. 라벨은 그대로 둔다. 프리뷰 배포가 아니다.
이 댓글은 grok-bot이 작성했습니다
fix(codex): gate gpt-5.6 native models by entitlement
fix(codex): gate gpt-5.6 native models by entitlement
fix(codex): gate gpt-5.6 native models by entitlement (#2550)
lidge-jun commentedon Aug 25, 2026
Landed via #2550 at e42778a
fix(codex): raise a stale runtime's client version to the measured ga…
fix(codex): raise a stale runtime's client version to the measured ga…
fix(codex): raise a stale runtime's client version to the measured ga…
fix(codex): raise a stale runtime's client version to the measured ga…
fix(codex): gate gpt-5.6 native models by entitlement (lidge-jun#2550)
fix(codex): gate gpt-5.6 native models by entitlement (lidge-jun#2550)
fix(codex): raise a stale runtime's client version to the measured ga…