Repository navigation
fix(openai): preserve VS Code IDE context in HTTP Responses - #8929
Merged
Wei-Shaw merged 1 commit intoNov 20, 2026
Merged
Conversation
riofutab
added a commit
to riofutab/sub2api
that referenced
this pull request
Nov 20, 2026
- 带入上游 11-17 至 11-18 已合的 PR,同步基准更新为 2af3f1e:GPT-6.2 Sol/Astra(Wei-Shaw#8906)、Ultra Fast 分组强制与渠道倍率(Wei-Shaw#8812 Wei-Shaw#8914)、首字前空闲换号受预算约束(Wei-Shaw#8920)、缓存创建 TTL 明细(Wei-Shaw#8174)及两项性能优化;Wei-Shaw#8577 与 Wei-Shaw#8598 fork 已有等价实现。 - 缓存创建 TTL 改用上游 Wei-Shaw#8174,撤回 fork 先前带入的 Wei-Shaw#8237;冲突处保留 fork 的 advisor 用量解析。 - 合入 19 个开放 PR:VS Code IDE 上下文(Wei-Shaw#8929)、Claude Code CCH 签名恢复(Wei-Shaw#8889,默认关闭)、等响应头时发 ping(Wei-Shaw#8964)、408 换号、账号恢复调度与批量编辑等修复,以及 Antigravity 假 429、裸 429 冷却范围、容量 503 换号、空流不冷却(Wei-Shaw#8975 含 Wei-Shaw#8627 新版)。 - compat 空流与 MALFORMED_FUNCTION_CALL 保留 fork 带的 Wei-Shaw#7899 行为,相关上游测试按 fork 行为调整;GPT-6.2 模型名后缀的推理档位补上校验。 - 后端全量 unit、golangci-lint、前端 lint/typecheck/vitest 与 CI 集成测试通过。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #8857. Follow-up to #8769 and the maintainer’s review of #8680.
VS Code sends the active file, selection and open tabs as an untrusted
ide_contextentry. Codex serializes it asagent.ide_context, a standalonefunction_call_outputwithout acall_id. Onmain, the HTTP Responses handler rejected that input with 400 before selecting an upstream. The shape was verified against the published OpenAI extension, version 26.51111.21308 and the Codex context producer.This extends the existing user-message normalization to
ide_context, theuntrusted_contentfallback and approved-plan chunks. Text and item order are preserved, including whitespace-only plan fragments. All three require a matching namespace, name and JSON string output. Ordinary tool results continue through call-ID validation.Verification
mainwith zero upstream calls, then HTTP 200 on this branch with one upstream call. The forwarded item was a user message containing the exact IDE text, followed by the original user prompt.untrusted_contentandproposed_plan.go test -tags=unit ./internal/handler -count=1 -timeout=300sgo test -tags=unit ./internal/service -run '^TestValidateFunctionCallOutput' -count=1 -timeout=180sgofmt -landgit diff --checkare clean.