You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
修复前:node --import tsx --test packages/web-server/test/ch-thread-tree-restore.test.ts,两个恢复入口均复现失败(0 passed / 2 failed,child must be restored with parent)。
The change makes restoring a Thread also restore archived descendants that sit on pages the Web instance never loaded, and it reports a failure when their status cannot be confirmed. The focused tests cover the main paths, and no actionable merge-blocking issue remains. One narrow edge case remains: when the native runtime is unavailable in an externalOnly Host, descendants may not be restored. That case is not worth blocking the merge.
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
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
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.
Summary
修复 Web 恢复父 Thread 时漏掉未加载归档页中的原生后代。改动集中在 Web Server 的归档级联逻辑,并补充回归测试和现有功能文档。
workspace/unarchiveSession或session/unarchive,RPC 返回成功,但没有向未加载的原生子 Thread 发送恢复请求。b65ae255b的跳过条件把“不在 Web 已加载归档 ID 集合中”当作“已恢复”。Host 契约明确规定,原生归档 ID 只描述返回页,集合外的后代状态仍是未知。officialCursor.live:null并跟随officialCursor.archived到结束;确认未归档后才跳过。一次级联共用一次确认,读取失败或重复游标按现有部分失败语义报告,其他已知归档后代继续恢复。thread/unarchive;核对到的原生实现会在没有归档 rollout 时返回错误,不能假设重复恢复是 no-op。归档方向的跳过条件与原行为一致,父 Thread 的原生错误也保留。Related issues
b65ae255b。no rollout found#852 / fix(web): converge archive state for already-archived native Threads #853 处理重复归档后的投影收敛,另行处理。Test plan
node --import tsx --test packages/web-server/test/ch-thread-tree-restore.test.ts,两个恢复入口均复现失败(0 passed / 2 failed,child must be restored with parent)。npm run typecheck通过。npm run lint通过,包含包边界检查;最终改动 TS 文件的定向 ESLint 通过。git diff --check和预提交格式检查通过。openai/codex@b1573f102413e96a6481087922bf425231222dee。npm test、Rust 或浏览器套件。定向测试命令: