fix(release): 完成官方发布身份与 legacy CAS 归属保护
bat-rust / Build and test Rust (push) Canceled after 0s
bat-rust / Build and test Go API (push) Canceled after 0s

This commit is contained in:
2026-09-13 15:34:42 +08:00
parent 5bae90cb14
commit 37d49c9793
11 changed files with 416 additions and 67 deletions
+10 -5
View File
@@ -1,6 +1,6 @@
# BlueArchiveToolkit 当前工作区状态
- **更新时间**2026-09-12
- **更新时间**2026-09-13
- **状态来源**:本地工作区盘点、代码验证和最新提交
- **状态分支**`experiment`
- **最新已推送功能提交**:以当前 `git log --oneline -1` 为准
@@ -58,12 +58,17 @@ output-root 单写者锁和事务日志恢复
current、version-state、version 目录,publish 只有最终 `verified` phase 才能恢复为已提交。
localized release 还写入实际 bytes/BLAKE3、完整 source mapping identity 和 destination
index 的 `localized-distribution-manifest.json`official download manifest 同样持久化
canonical mapping identity 和 destination index。`release.distribution(destination=...)`
只比较 persisted identity、查目标索引并校验单文件,返回 exactly one entry 且不在分发
热路径执行完整 release audit`release.cleanup execute` 与 official sync 共用同一个
canonical mapping identity 和 destination index。新 official release 在完整发布验证后
额外写入独立的 `official-distribution-publication.json`,关联 release ID、mapping
identity、manifest content identity 和 entry count。`release.distribution` 只选择
publication identity 与当前 official manifest 一致的 release`destination=...`
比较 persisted identity、查目标索引并校验单文件,返回 exactly one entry 且不在分发热路径
执行完整 release audit;缺少 publication metadata 的 legacy release 仍可读和清理,但不
满足 distribution-ready。`release.cleanup execute` 与 official sync 共用同一个
`.official-sync.lock`localized cleanup 继续使用 `.localized-release.lock`。legacy CAS
manifest 首次 cleanup 时按 output-root scope、release generation 和稳定 source identity
迁移;已有 basename ledger 的部分 cleanup 保持兼容 key,完成后同名新 generation 不再复用。
迁移;已有 basename ledger 的部分 cleanup 只有在 output-root 持久化的显式 compatibility
marker 存在时才保持兼容 key,无法证明归属时拒绝 cleanup;完成后同名新 generation 不再复用。
---