Commit Graph
4806 Commits
Author SHA1 Message Date
王鹏 f863f664ac fix(frontend): clear stale DataTable row caches 2026-07-15 03:33:35 +08:00
王鹏 2c13ed32e7 fix(images): preserve JSON completion boundaries 2026-07-15 03:15:47 +08:00
王鹏 d4da138cf5 fix(openai): preserve reset count on malformed details 2026-07-15 02:51:56 +08:00
王鹏 b286cca0c4 fix(openai): repair concatenated Responses stream events 2026-07-15 02:41:23 +08:00
jjaw 31a0efc747 退休已停用分组的调度缓存桶 2026-07-15 01:07:26 +08:00
蔡及 22e97898bb fix: gofmt on parallel tool regression test 2026-07-15 00:59:28 +08:00
蔡及 1eb79df0d3 fix: golangci-lint issues (unused helpers, empty branch, errcheck, gofmt) 2026-07-15 00:58:42 +08:00
蔡及 07732a5a35 test: add regression tests for parallel tool_use ghost delta (#4193)
Three tests covering the CC→Responses→Anthropic finalize path:
- TestStreamingParallelToolUseNoGhostDelta: full end-to-end with two
  parallel tool_calls, asserts every content_block_delta targets a
  started block
- TestStreamingParallelToolUseSecondToolPackedArgsDone: focused test
  where tool 1 streams deltas and tool 2 has packed .done args
- TestStreamingThreeParallelToolsAllPackedDone: three tools all with
  packed .done, the most extreme case

All three fail on unfixed code (ghost deltas on wrong indices) and
pass after the fix.
2026-07-15 00:47:04 +08:00
蔡及 3504b8cc88 perf: direct Anthropic↔ChatCompletions bridge for force-chat accounts
Skip the Responses API intermediate representation on the /v1/messages
force-chat path. Previously every streaming token ran through two state
machines (CC→Responses→Anthropic); now it runs through one (CC→Anthropic).

New file backend/internal/pkg/apicompat/chatcompletions_anthropic_bridge.go:
- AnthropicToChatCompletionsRequest: request-side direct conversion
- ChatCompletionsResponseToAnthropic: non-stream response direct conversion
- ChatCompletionsChunkToAnthropicEvents + Finalize: single streaming state machine

openai_gateway_messages_chat_fallback.go rewired to use the direct bridge.
Existing 7 ForceChatCompletions end-to-end tests pass unchanged; 22 new
unit tests added including equivalence tests vs the double-conversion path.
2026-07-15 00:44:13 +08:00
蔡及 4f3b5110e2 fix: parallel tool_use ghost content_block_delta (index error)
resToAnthHandleFuncArgsDone used state.ContentBlockIndex directly
instead of looking up from OutputIndexToBlockIdx like
resToAnthHandleFuncArgsDelta does. When multiple tool_calls arrive
in parallel and arguments come as a packed .done (no prior delta),
the second+ tool would emit content_block_delta on an index that
was never content_block_start'ed, causing Claude Code to report
"Content block not found".

Fix: resolve block index from OutputIndexToBlockIdx, and skip the
delta if the block is already closed or the index doesn't match
the current open block.

Closes #4193
2026-07-15 00:44:09 +08:00
bestony 324a491671 feat: extend Server-Timing to authenticated user web APIs
Mirror the Admin UI Server-Timing opt-in for user-facing pages so
authenticated callers can inspect total/app/db/redis/deps metrics on
session, profile, keys, usage, payment, and related user APIs.

- Collect when X-User-UI-Request=1 or path is on the user allowlist
- Emit for non-admin only on allowlisted paths (header is not auth)
- Exclude payment public/webhook surfaces
- Mark matching SPA requests and allow the new CORS request header
2026-07-15 00:23:27 +08:00
jjaw 9da4cfbdcc 增加调度分组生命周期租约 2026-07-15 00:12:40 +08:00
jjaw 5e43c7faac 优化透传流事件边界刷新 2026-07-15 00:00:40 +08:00
wucm667 b28ac90364 fix(antigravity): preserve manually entered refresh token 2026-07-14 23:58:00 +08:00
jjaw 8523a52c07 优化调度缓存桶退休原语 2026-07-14 23:08:17 +08:00
haruka ad3522e34b fix(frontend): preserve legacy Codex config mode 2026-07-14 22:41:38 +08:00
Tiantianr 74e296703a fix(openai-ws): make first-message timeout configurable
Add a dedicated client first-message timeout while preserving the legacy 30-second default.

Use the resolved value for both the WebSocket read deadline and structured timeout logs, and document tuning for large requests or slow links.

Add configuration, validation, handler, and resolver regression coverage.

Refs #4158
2026-07-14 22:40:05 +08:00
wucm667 25e6688af6 [verified] fix: apply long-context pricing to account cost 2026-07-14 22:31:39 +08:00
jjaw 92edda2f6e 优化透传图片意图判定复用 2026-07-14 21:57:26 +08:00
zh239ns bef520b191 fix(images): report decoded OAuth output dimensions
ChatGPT OAuth may normalize explicit image size controls to auto while returning smaller raster bytes. Decode final image headers so Images API metadata and tier billing reflect the actual output for both streaming and non-streaming OAuth responses.
2026-07-14 20:31:17 +08:00
bestony ba5b6970be fix(openai): include proxy host in upstream_failover_switching logs
Enrich openai.upstream_failover_switching structured logs with proxy
identity fields (proxy_id, proxy_name, proxy_host, proxy_port) so
operators can see which outbound proxy failed when switching accounts.
Matches the existing gateway.forward_failed / websocket_proxy_failed
logging pattern.
2026-07-14 19:33:56 +08:00
bestony b000aac474 fix(openai): include proxy host in websocket_proxy_failed logs
Add proxy_id/proxy_name/proxy_host/proxy_port fields to openai.websocket_proxy_failed so operators can identify which proxy failed without extra lookups. Matches the existing gateway.forward_failed logging pattern.
2026-07-14 19:32:49 +08:00
cat 6485081122 feat(frontend): 标明 OpenAI 认证模式 2026-07-14 19:25:13 +08:00
cat ec7c1b6f72 fix(openai): 修复 Agent Identity CI 问题 2026-07-14 19:24:56 +08:00
bestony eedd9b147d feat(admin): add optional ID column on groups list
Add a toggleable group ID column in /admin/groups column settings.
It shows the group id (e.g. #1), is hidden by default for new and
existing admins via column-settings version migration, and remains
sortable against the existing backend sort_by=id support.
2026-07-14 19:19:22 +08:00
bestony 2157ee344b feat(keys): add optional ID column on /keys page
Expose API key ID in the keys table column settings so users can show
or hide it. Hidden by default; bump column-settings version so existing
preferences also keep ID hidden until toggled on.
2026-07-14 19:18:53 +08:00
cat d68a2aac1a chore(openai): 同步上游并解决认证冲突 2026-07-14 19:04:04 +08:00
haruka f09d63f54e fix(frontend): address Codex config review feedback 2026-07-14 18:31:06 +08:00
cat f479a5d10c fix(openai): 收紧 Agent Identity task 生命周期 2026-07-14 18:09:59 +08:00
cat bd1399f81e fix(openai): 允许 Agent Identity 无令牌拨号 WS 2026-07-14 17:41:17 +08:00
Lyonle 8b37ba8828 perf(risk): optimize keyword moderation hot path 2026-07-14 17:39:49 +08:00
cat 10aa88aab9 fix(openai): 补齐身份失效恢复路径 2026-07-14 17:19:15 +08:00
wucm667 806bb23053 fix: add root Codex models alias 2026-07-14 17:16:24 +08:00
cat 3fe7b4da78 fix(openai): 闭合直通 WS 恢复与错误脱敏 2026-07-14 17:05:47 +08:00
cat 57cf2df09f fix(openai): 收紧 Agent Identity 恢复与脱敏 2026-07-14 17:05:47 +08:00
cat 1dab126944 feat(openai): 支持 Agent Identity 认证 2026-07-14 17:05:46 +08:00
shaw da85cc7e47 chore: update sponsors 2026-07-14 17:01:39 +08:00
jjaw 86800a8cd0 优化内容会话种子字段扫描 2026-07-14 16:53:21 +08:00
haruka e2028a814e fix(frontend): update Codex API key snippets 2026-07-14 16:41:44 +08:00
jjaw 23f93a9348 优化 Responses 流式事件边界刷新 2026-07-14 16:38:37 +08:00
jjaw a8afc20969 优化 Ops 队列深度账号查询 2026-07-14 16:18:26 +08:00
github-actions[bot] 7c717365ef chore: sync VERSION to 0.1.155 [skip ci] 2026-07-14 07:08:08 +00:00
Heatherm Huang 4c764d3fc9 test(grok): use healthy quota account fixture 2026-07-14 15:07:09 +08:00
Heatherm Huang a13a6113dd fix(grok): route generic account refresh correctly 2026-07-14 15:00:52 +08:00
Heatherm Huang cb7dfea5a9 test(grok): update default model fixture 2026-07-14 14:55:30 +08:00
Heatherm Huang 81b8b78378 fix(grok): resolve upstream OAuth imports 2026-07-14 14:55:30 +08:00
Heatherm Huang b32b815e46 fix(grok): harden OAuth pool recovery 2026-07-14 14:55:30 +08:00
Heatherm Huang 91ae671a58 fix(grok): satisfy lint checks 2026-07-14 14:55:30 +08:00
Heatherm Huang 343390057d fix(grok): fail over OAuth credential errors safely 2026-07-14 14:55:30 +08:00
Wesley Liddick 41cec0db05 Merge pull request #4154 from sir1st/codex/fix-native-responses-namespace
fix: support namespace tools in native responses
v0.1.155
2026-07-14 14:51:14 +08:00