Repository navigation
fix(codex): 支持运行中从卡片切换思考强度 - #2755
Merged
Merged
Conversation
Zzzen
requested review from
47seek,
LucasIcarus,
deepcoldy,
xiaoxueSunn and
xiongz-c
as code owners
November 3, 2026 15:52
Owner
|
你好,这个 PR 的自动评审群已建,麻烦点击链接加入群聊、查看评审意见并跟进后续修改: 另外你暂时不在自动拉群名单里,也可以把 GitHub 账号和飞书信息补进名单文档,补好后后续评审会自动拉你进群:https://bytedance.larkoffice.com/wiki/WJ1nwWbtxi89erkNGNbcgkt9nUe (本条为自动流程发出的提示消息) |
deepcoldy
approved these changes
Nov 5, 2026
deepcoldy
left a comment
Owner
There was a problem hiding this comment.
评审通过。
- 改动范围:4 个文件 +100/−7。运行中的本地受管 Codex 会话从状态卡片选择思考强度时,复用 /effort 已验证的原生菜单 IPC 路径(updateCodexCliEffort),收到原生「下一轮生效」回执后才写偏好并落盘,落盘失败回滚;卡片先同步返回「切换中」释放回调门,回执经 worker/两层 generation/原生会话 ID 多重归属校验后再刷新卡片与通知。挂起会话与包装器 CLI 保留原有冷启动保存路径,其它 CLI 不受影响。
- 同步提交的冲突解决经独立复现核对:唯一冲突为 card-handler.ts 的 worker-pool import 行两侧新增符号并集,无夹带、未回退主干内容(相对合并点主干仅这 4 个文件 +100/−7)。
- 验证:tsc 0 error;相关定向测试 914 项通过;bun:test 腿相关文件 27 项通过(card-handler 类测试与既有形态一致由 vitest 承载);删除 nonce/归属/分流/应答等守卫的变异均被对应测试咬红。
- CI 在本 head 首跑 10 个 job 全部成功,含 bun-test。
- 4 项非阻断建议(非法选项与两个冷启动分支补测、回执归属余维度补测、菜单等待期内重复点击的两条提示文案),可后续跟进。
|
🚀 Released in v3.57.1 |
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
运行中的 Codex 会话从状态卡片选择「思考强度」时,原来被空闲检查拦截,且只能保存下次冷启动设置;同一会话的
/effort已支持原生菜单切换。本次让运行中卡片入口复用该路径,收到原生确认后从下一轮生效,当前轮保持原参数。变更与影响范围
卡片示意
下图为已有卡片文案示意:本次将运行中下拉框接入上半部分的「下一轮生效」确认路径,冷启动设置仍沿用下半部分的提示。此图为离线示意,并非飞书客户端实测截图。
验证
基于主干
5a88eda6,使用 Bun 1.4.3 验证:完整构建及上述回归通过,覆盖本次原生切换、主干新增模型/话题强度快捷入口以及其它 CLI 的共享卡片路径。
使用真实 handler、worker-pool、菜单与模型解析组件及假时钟运行本地集成探针,6/6 通过;存储、菜单 IO 与外部投递边界受控,未实际连接 SQLite 或 CLI:
原有变异复验:移除 nonce 校验或异步结果归属校验,对应用例均失败。
未部署、未重启共享 daemon,未运行真实 Codex CLI / 飞书客户端端到端验证。