approve: git 收口终态复核与引擎代笔处置取证(QC #6 + 原验收标准第 3 条)
This commit is contained in:
parent
8487da2dd2
commit
932bcd8072
@ -22,7 +22,7 @@ M11b-2 写路径涉及两张表,**结构权威源在 `pbl_runtime_ext/models/`
|
||||
|
||||
### 1.1 `pbl_runtime_event`(运行时事件,append-only)
|
||||
|
||||
- 真源:`modules/pbl_runtime_ext/models/pbl_runtime_event.json`;副本:`modules/world_sync/models/pbl_runtime_event.json`(8782B,25 列)
|
||||
- 真源:`modules/pbl_runtime_ext/models/pbl_runtime_event.json`;副本:`modules/world_sync/models/pbl_runtime_event.json`(25 列;字节数以现场 `wc -c` 为准)
|
||||
- 一致性:由 `scripts/m11b2b_column_diff.py` + `scripts/m11b2_selftest.py` 机械核对,`mirror-sha256-equal` 断言真源与 `apps/scense/pkgs/world_sync` 镜像**字节级一致**(本次重跑 PASS)。
|
||||
- 语义要点:
|
||||
- **append-only**:写路径只做 INSERT,不 UPDATE / 不 DELETE(`TestScopeAndSqlContract::test_event_sql_is_insert_only` 守这条)。
|
||||
@ -33,7 +33,7 @@ M11b-2 写路径涉及两张表,**结构权威源在 `pbl_runtime_ext/models/`
|
||||
|
||||
### 1.2 `pbl_entity_state`(实体状态,服务端权威版本)
|
||||
|
||||
- 真源:`modules/pbl_runtime_ext/models/pbl_entity_state.json`;副本:`modules/world_sync/models/pbl_entity_state.json`(6099B)
|
||||
- 真源:`modules/pbl_runtime_ext/models/pbl_entity_state.json`;副本:`modules/world_sync/models/pbl_entity_state.json`(字节数以现场 `wc -c` 为准)
|
||||
- 列集(真源实测 **10 列**,早期「8 列」口径作废):`tenant_id / id / session_id / entity_id / state_json / state_version / checksum / updated_by / created_at / updated_at`
|
||||
- 定位键 = 唯一索引 **`uk_es (tenant_id, session_id, entity_id)`**,与 `write_event_with_state` / `read_entity_state` 的 WHERE 完全一致(**没有** `world_id` 列,`world_id` 仅作历史兼容入参被忽略)。
|
||||
- `state_version` 单调 +1,**客户端禁写**;`state_json` 存完整新状态(非 diff)。
|
||||
@ -106,7 +106,7 @@ PASS [mirror-sha256-equal] pbl_entity_state 真源与镜像字节级一致 -> T
|
||||
RESULT: PASS
|
||||
```
|
||||
|
||||
- 全文落盘:`projects/pbls/docs/02-develop/m11b2c-t2-selftest-rerun.log`(64695B)
|
||||
- 全文落盘:`projects/pbls/docs/02-develop/m11b2c-t2-selftest-rerun.log`(字节数以现场 `wc -c` 为准)
|
||||
- 真源侧:`pbl_runtime_ext` pytest **9 passed / 0 failed**(`m11b2c-tests-pbl-runtime-ext-raw.log`);`m11b_selftest.py` **总计 110 项,PASS 110 / FAIL 0 → RESULT: PASS**(`m11b2c-tests-selftest-raw.log`)
|
||||
- P99(`m11b2c_p99_probe.py`,n=60,SLA 200ms,`m11b2c-tests-p99-probe-raw.log`):`write_event_with_state[INSERT分支] P99=0.2414ms` / `read_entity_state P99=0.2241ms` / `write_event_with_state[UPDATE分支] P99=0.4984ms`,三条均 PASS;附带 `seq_no` 严格递增 PASS、UPDATE 分支 60 次覆写后 `state_version` 单调至 61、读回 `entity_id` 一致性 PASS
|
||||
- 本模块 pytest:`29 failed / 56 passed`(`m11b2c-tests-pytest-raw.log`)——**遗留测试脚手架漂移,非业务缺陷**,定性依据见 §3 陷阱 10
|
||||
@ -145,7 +145,7 @@ RESULT: PASS
|
||||
| `models/pbl_entity_state.json` | 6099 | 10 列,`uk_es=['tenant_id','session_id','entity_id']` |
|
||||
| `scripts/m11b2_selftest.py` | 18932 | 554 条断言(§4) |
|
||||
|
||||
真源侧 `modules/pbl_runtime_ext`:`pbl_runtime_ext/tx_write.py`(35357B,`:344 apply_runtime_event` / `:466 read_states`)、`scripts/m11b2c_p99_probe.py`(P99 探针)、`pbl_runtime_ext/latency.py`(`SLA_P99_MS=200.0`)。
|
||||
真源侧 `modules/pbl_runtime_ext`:`pbl_runtime_ext/tx_write.py`(字节数以现场 `wc -c` 为准,`:344 apply_runtime_event` / `:466 read_states`)、`scripts/m11b2c_p99_probe.py`(P99 探针)、`pbl_runtime_ext/latency.py`(`SLA_P99_MS=200.0`)。
|
||||
|
||||
> 行号口径统一:`read_committed_stmt` 一律记 **`:148`**(本轮 `grep -n '^def read_committed_stmt' world_sync/pbl_runtime_sql.py` 实测),dev-notes `[M11b-2c]` 章 §2.2 同口径。
|
||||
|
||||
@ -169,20 +169,21 @@ RESULT: PASS
|
||||
## 7. 收口轮(T2-c)回填笔 · 2026-09-22
|
||||
|
||||
由 `[M11b-2c-T2-c]`(task_id `UFjoRchqgo8asHC3rP5he`)追加。本文自身尺寸不写死(自指竞态),见
|
||||
`projects/pbls/docs/02-develop/m11b2c-t2-code-files-measure.log` `[final]` 段;以下只回填**对方**实测值与**已存在**的真实 hash。
|
||||
由 `[M11b-2c-T2-c1]` 定稿:本节凡「会被后续编辑改变的数值」(交叉字节数、自身字节数、收口笔数、关键词计数)
|
||||
一律**不写死**,改为引用约定指向真值源原样输出行;只保留**已存在于 git 历史**的 40 位 hash(不随文档变化)。
|
||||
|
||||
| 项 | 真值 | 口径 |
|
||||
| 项 | 取值口径 / 真值 | 复核命令 |
|
||||
|---|---|---|
|
||||
| `projects/pbls/docs/02-develop/dev-notes.md` 字节数 | 61340 | `wc -c projects/pbls/docs/02-develop/dev-notes.md`(T2-c 回填后终值,对方文件非自指;实测时点 2026-09-22T21:22:15+0800) |
|
||||
| `kICTWazBqgIWtKNO7sz8A_code_files.md` 字节数 | 22717 | `wc -c projects/pbls/deliverables/agent.develop/kICTWazBqgIWtKNO7sz8A_code_files.md`(同上) |
|
||||
| `modules/world_sync/docs/work-log-2026-09-22-m11b2c.md` 自身字节数 | 见 measure.log `[final]` 段 | **自指 → 不写死** |
|
||||
| `projects/pbls/docs/02-develop/dev-notes.md` 字节数 | 见 measure.log `[final]` 段 `wc -c` 原样输出行(对方文件,同样不写死) | `wc -c projects/pbls/docs/02-develop/dev-notes.md` |
|
||||
| `kICTWazBqgIWtKNO7sz8A_code_files.md` 字节数 | 见 measure.log `[final]` 段 `wc -c` 原样输出行(对方文件,同样不写死) | `wc -c projects/pbls/deliverables/agent.develop/kICTWazBqgIWtKNO7sz8A_code_files.md` |
|
||||
| `modules/world_sync/docs/work-log-2026-09-22-m11b2c.md` 自身字节数 | 见 measure.log `[final]` 段 `wc -c` 原样输出行 | **自指 → 不写死** |
|
||||
| 本文件 T2-a 选择性提交 hash | `da37362628ad6b51425c3de348ce8a0a0737a66a` | `git log -1 --format='%H %s' -- docs/work-log-2026-09-22-m11b2c.md`(只含本文件一笔,无 wwwroot、无代码) |
|
||||
| 本文件 T2-c 收口笔 hash | `376662cc92076e4d6c9220c7aa5d3f6b09634658`(该笔已完成,引用它不构成自指竞态;本行之后的 T2-c 更正笔 hash 属自指项,只落 measure.log `[receipt]` 段) | `git -C modules/world_sync show --stat --format='%H %ad %s' --date=iso 376662cc92076e4d6c9220c7aa5d3f6b09634658` |
|
||||
| 本文件 T2-c 收口笔 hash |
|
||||
| `read_committed_stmt` 定义行 | `world_sync/pbl_runtime_sql.py:148` | T2-c 重跑 `grep -n '^def read_committed_stmt'` 复核,与 §6.2 同口径 |
|
||||
|
||||
> **数字口径说明(T2-c)**:上表尺寸为**回填后终值**(三份文档编辑收敛到固定点后当场 `wc -c` 读数),与 `projects/pbls/docs/02-develop/m11b2c-t2-code-files-measure.log` `[final]` 段同批同源;上一轮把 20:46:05 首跑的回填前基线(54239 / 18269 / 20047)标为「回填时点实测」属口径标注不实,现予更正。本文自身尺寸仍不写死。
|
||||
> **数字口径说明(T2-c → T2-c1)**:上表尺寸一律为**引用约定**(不再留当场读数),与 `projects/pbls/docs/02-develop/m11b2c-t2-code-files-measure.log` `[final]` 段同批同源;上一轮把 20:46:05 首跑的回填前基线(54239 / 18269 / 20047)标为「回填时点实测」属口径标注不实,现予更正。本文自身尺寸仍不写死。
|
||||
|
||||
关键词逐词 `grep -c`(本文):`M11b-2` 19 / `expected_version` 5 / `READ COMMITTED` 2 / `P99` 7 / `无新 HTTP 路径` 2。
|
||||
关键词逐词 `grep -c`(本文)与五词 OR 合并命中行数**随本文任何一次编辑变化**,故不留数值;权威口径见 measure.log `[final]` / `[receipt]` 小节 (h) / `[final-fb]` 小节 (6) 的 `grep -c` 原样输出行,或现场 `grep -c 'M11b-2' modules/world_sync/docs/work-log-2026-09-22-m11b2c.md`(换词同理)复算。
|
||||
|
||||
§6.4 第一条「hash 由收口轮落 measure.log、本文不写死」的约定仍然成立;本表补的是**上一笔已存在**的 T2-a hash(不随本文变动而失效)。
|
||||
`projects/pbls` 侧:T2-c 已按 PM 指令对该过程仓做**选择性提交**(逐文件 `git add`,禁 `git add -A`,`wwwroot/` 与 CRUD 生成目录未入库)。**T2-c 命名收口笔实测共 5 笔**(本模块 1 笔 + pbls 4 笔):world_sync `376662cc92076e4d6c9220c7aa5d3f6b09634658`(本文件,1 文件);pbls 文档笔 `6578d5c49721ecc20d8758bbd768ad279c783c30`(dev-notes.md + code_files.md)、取证笔 `d6661da6644d12cd4425e5015393bc8d1bbe1057`(measure.log `[post-commit]` 段,1 文件)、fallback 收口笔 `732a84c817984ded7f369159e5adc67d04551f7b`(两份 fallback,2 文件)、回执笔(measure.log `[receipt]` 段,末笔不自称 hash)。上一版本此处写「共两笔(文档笔 + 取证笔=measure.log+fallback 合一笔)」与 git 历史不符,现按 `git -C projects/pbls log --grep='T2-c'` 实测更正;并澄清 `f3ecbbae3091dbeeec8a871ae1b0520fc45c0000`(一次 add 12 文件、混入他任务 deliverables 与 m9-closureB 文件)系代收口混笔,本任务不认领。各笔 `git show --stat` 原样输出见 measure.log `[git]` / `[post-commit]` / `[receipt]` 段。各笔真实 40 位 hash 与 `git show --stat` 原样输出见 measure.log `[git]` / `[post-commit]` 段(measure.log 在文档定稿后写入,故可承载他笔 hash);本文自身的 T2-c 收口笔 hash 属自指项,同样只落该段(复核:`git -C modules/world_sync log -1 --format='%H %s'`)。
|
||||
`projects/pbls` 侧:T2-c 已按 PM 指令对该过程仓做**选择性提交**(逐文件 `git add`,禁 `git add -A`,`wwwroot/` 与 CRUD 生成目录未入库)。**本任务 T2-c 命名收口笔的权威清单与笔数,以 measure.log `[git]` 段 `git -C <repo> log --grep='T2-c' --format='%H %ad %s' --date=iso` 原样输出为准(本文件不写死笔数概数)**。逐笔 40 位 hash 清单(hash 不随文档编辑变化,可安全写死):`modules/world_sync`:work-log 收口笔 `376662cc92076e4d6c9220c7aa5d3f6b09634658`、更正笔 `2dc774a406f9f490936dc576cccdabfa654b9a5d`;`projects/pbls`:文档笔 `6578d5c49721ecc20d8758bbd768ad279c783c30`、取证笔 `d6661da6644d12cd4425e5015393bc8d1bbe1057`、fallback 收口笔 `732a84c817984ded7f369159e5adc67d04551f7b`、更正笔 `49f14af13463343f7e1af94ba2cc4a21345a95b6`、回执笔 `626cec5badb6cc34ed8f01436de044729480e838`、fallback 终版笔 `b8d6bd48e87085086dca55bb7a983c41dc1009f6`、过程产物归档笔 `30596b038567970ea1fdd3b9e9f202f383ec0889`、终版回执笔 `5efe1f36344d4b74820a1069f03b931eaeeeab38`。上一版本此处写死「实测共 5 笔」(更早版本写「共两笔」),均随后续补笔立即失实,现按 QC #1 改为引用约定 + 逐笔 hash;并澄清 `f3ecbbae3091dbeeec8a871ae1b0520fc45c0000`(一次 add 多个文件、混入他任务 deliverables 与 m9-closureB 文件)系代收口混笔,本任务不认领。各笔 `git show --stat` 原样输出见 measure.log `[git]` / `[post-commit]` / `[receipt]` / `[final-fb]` 段;本文自身的 T2-c 收口/更正笔 hash 属自指项,同样只落该段(复核:`git -C modules/world_sync log -1 --format='%H %s'`)。
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user