Skip to content

fix(continuity): 修复宿主结果与空参数标记省略导致的续接误判 - #2899

Open
lxjmaster wants to merge 1 commit into
jlcodes99:mainfrom
lxjmaster:fix/continuation-history
Open

lxjmaster wants to merge 1 commit into
jlcodes99:mainfrom
lxjmaster:fix/continuation-history

Conversation

@lxjmaster

Copy link
Copy Markdown

问题与修复

续接校验会将终端客户端注入的合法宿主结果误判为缺失工具调用;客户端回传完整历史时省略空的 encrypted_function_args: [],也可能让已保存的检查点匹配失败,返回 continuation_history_incomplete。

  • Rust 校验与 Go 调用 ID 归一化一致识别 codex_app、codex_tui 下的 create_thread / send_message_to_thread 宿主结果,避免借用无关工具调用的 ID。宿主载荷及显式调用 ID 仍须通过原有校验。
  • 完整历史检测与检查点合并共用匹配逻辑:仅当经过身份验证的同一调用方、同一线程检查点中的 collaboration 调用其余字段完全相同时,允许回传历史省略已保存的空参数标记。
  • 该兼容仅限 spawn_agent、send_message、followup_task;不接受反向增加标记、非空或 null 标记、参数变化或嵌套字段变化,不修改传入历史或推断加密引用。
  • 补充隔离边界、失败与取消、重启、额度耗尽后账号切换及空标记省略的回归覆盖。

验证

  • 239 项 Rust 续接相关测试通过,覆盖 identity、HTTP 上下文重建、检查点与 WebSocket。
  • Go sidecar 全量测试、嵌套执行器测试及续接执行器定向测试通过。
  • 6 个真实 Go → Rust 工作进程桥接场景通过,覆盖两种宿主命名空间、工作进程重启、429 后账号切换及空标记省略。
  • git diff --check 通过。

此 PR 基于最新上游 main,仅包含续接修复;与自定义模型功能 PR 独立。验证使用合成历史,未重放真实用户会话。

Recognize terminal host results without borrowing unrelated tool call IDs. Accept omitted empty plaintext markers only against an otherwise identical caller-scoped checkpoint, and cover restart, failover, cancellation and isolation boundaries.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant