refactor: dedupe diagnostics fallback helpers#6
Merged
Conversation
Release-Sync: yes Release-Version: 2026-04-02.140640 Release-Date: 2026-04-02
Release-Sync: yes Release-Version: 2026-04-02.162241 Release-Date: 2026-04-02
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.
摘要
这个 stacked PR 是接在 runtime outcome diagnostics surface 之上的一轮去重收口。
目标不是再改一轮 diagnostics contract,而是在不破坏已安装 payload / vendored runtime 自包含约束的前提下,把重复的 outcome 逻辑尽量收回到一处。
现在 repo-local 路径优先复用 installer/outcome_contract.py 里的共享 helper;只有安装态 / vendored 仍然必须独立运行的地方,才保留最小 fallback
mirror。
改动内容
为什么要做
上一轮 diagnostics surface 已经把结果 contract 收口了,但 fallback 路径和部分渲染路径里,仍然保留了重复的 primary_code / action_level / summary 逻
辑。
这会让下面几层之间继续存在漂移风险:
这个 PR 的作用就是在不破坏 standalone 执行前提的情况下,把这层漂移面继续压小。
范围边界
这个 PR 不追求“不惜代价的零重复”。
原因是安装态 bootstrap helper 和 vendored fallback 仍然必须满足“脱离源码仓库包结构也能执行”的约束,所以仍需要保留一层窄镜像。
这一轮的收口定义是:
验证
提交前本地已通过:
commit hook / preflight 也已通过: