Skip to content

fix(changelog): restore the release history the mermaid merge truncated - #1089

Merged
Menghuan1918 merged 2 commits into
omdsh-dev:devfrom
UNscientific-9:fix/changelog-restore
Nov 4, 2026
Merged

Menghuan1918 merged 2 commits into
omdsh-dev:devfrom
UNscientific-9:fix/changelog-restore

Conversation

@UNscientific-9

Copy link
Copy Markdown
Contributor

问题

2026-10-29 合入 #1040(mermaid 沙箱 iframe)时,合并提交 04c6cb8 把两个 changelog 从完整历史截成了顶部几段:

文件 两个父提交 合并结果 现在 dev
CHANGELOG.md 656 / 658 行 41 行 41 行
CHANGELOG_EN.md 496 / 497 行 27 行 27 行

截断点在 v0.28.1 中间:v0.28.1 后半段、v0.28.0 及更早的全部发布记录都没了。#1077(dev → main 0.29.0 发版)现在合并会从 main 删掉 628 行发布历史。

修复

  • 从截断前的 dev 侧父提交 66337ff 恢复 v0.28.1(中文)/ v0.28.2(英文)以下的全部内容,保留当前顶部的「未发布 / v0.29.0 / v0.28.2」新条目。
  • 恢复后中文 36 个版本段、英文 35 个版本段,最老 v0.12.3;尾部与截断前逐字一致。
  • 新增 tests/changelog-integrity.spec.ts:两个文件都必须保留最老版本、版本段不少于 30 个,且英文不能列出中文没有的版本。用截断版跑,两个文件分别只剩 3 / 2 个版本段,测试直接红。

验证

  • pnpm typecheck ✅
  • eslint(排除本机 .tmp-crosscheck 已知污染)✅
  • pnpm test:2951 条中 2929 passed / 5 failed / 17 skipped;4 条是 Windows 未开开发者模式的符号链接 EPERM(已知环境问题),1 条 git-graph 并发超时、单独复跑 12/12 通过。
  • 新测试 2 passed;截断版判别性验证失败(符合预期)。

影响

只动两个 changelog 和一个测试,不改产品代码。

The omdsh-dev#1040 merge (04c6cb8) resolved CHANGELOG.md and CHANGELOG_EN.md from a
tree that had already lost everything below the top sections: both parents
were 656/658 (ZH) and 496/497 (EN) lines, the merge result was 41/27. The
file ended mid-v0.28.1, so v0.28.0 and every earlier release disappeared.

Restore the tail from 66337ff (the dev-side parent; its history is identical
to the other parent's from v0.28.1/v0.28.2 down) and keep the current top
sections, which already carry the batch's new entries. PR omdsh-dev#1077 (dev to main)
would otherwise delete 628 lines of main's release history.
A merge can drop the release history without any test noticing (04c6cb8).
Assert both files keep the oldest release, stay above the historical floor,
and that English never lists a release the authoritative Chinese file lacks.
The truncated 41/27-line files fail both checks.
@Menghuan1918
Menghuan1918 merged commit 4f6b763 into omdsh-dev:dev Nov 4, 2026
3 checks passed
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.

2 participants