W0.6 = bao-dam falsifiable DUY NHAT cua ca wave (broadcast 4(d): "moi kiem static-text deu
KHONG falsifiable; chi spawn-probe / assert-registry moi that-su chung-minh").
LECH SPEC CO CHU-DICH - spec v2 W0.6 chi dung 1 probe (CRLF) -> RESTART -> spawn. LO: neu spawn
FAIL, quan-sat do KHONG phan-biet duoc 2 gia-thuyet: "reader LF-only nen chet" vs "registry chua
nap file moi". Mot quan-sat, hai gia-thuyet => vo-nghia.
VA: dung them _lf-probe.md GIONG HET, khac DUNG 1 BIEN = line-ending.
CRLF ok + LF ok -> CRLF-tolerant (khoi restart)
CRLF x + LF ok -> CRLF-fatal CHAC-CHAN (LF chung-minh hot-reload CO chay)
CRLF x + LF x -> hot-reload KHONG chay -> chi nhanh nay moi can RESTART
Kiem bien don (soi byte, khong tin sed): _crlf-probe CR=276 LF=276 ; _lf-probe CR=0 LF=276 ;
od -c xac nhan "- - - \r \n n a m e : _ c r l f - p r o b e \r \n" ;
diff <(bo CR, bo dong name:) 2 file -> GIONG HET => bien duy-nhat = line-ending.
LUOT-1 (TRUOC restart) = nhanh 3: CA 2 probe not-found. Available list = 19 sub + plugin co
tu dau phien, khong co probe nao.
>>> NHOM CHUNG CUU 1 KET-LUAN SAI: _lf-probe THUAN LF (0 byte CR) cung chet y het => nguyen-nhan
KHONG PHAI CRLF. Neu lam dung spec (1 probe), lead se thay _crlf-probe chet va rat de ket-luan
"CRLF-fatal" - SAI, va sai THEO HUONG CO LOI cho cau chuyen (xac nhan L3 + giu R4 nac manh).
DO DUOC (moi, S120): registry agent = ANH-CHUP luc khoi phien; KHONG hot-reload agent file MOI.
Doi-chieu memory project_harness4_two_tier_model: ghi "agent file MOI = hot-reload OK" (verified
S107) KEM canh-bao ENV-DEPENDENT (hub ra ket-qua NGUOC S110). S120 do KHONG hot-reload => canh-bao
ENV-DEP xac-nhan lan nua, lan nay ngay trong repo SE. Cau "nghi ngo -> restart" cua memory = DUNG.
=> de-nghi thu hep memory o session-end: "hot-reload agent-file-moi = ENV-DEP, SE do KHONG an @S120".
2 probe = UNTRACKED CO Y. CAM `git add` - `.gitattributes` `* text=auto eol=lf` se NORMALIZE
mat CR = giet thi-nghiem. Hook khong phu .claude/agents/ nen khong tu commit.
WAL: ghim 3 buoc sau restart (LF TRUOC -> CRLF sau -> xoa 2 probe), + verify lenh kiem 276 CR
con nguyen. Day range hien = commit thuong 92de58f => moi wal: sinh sau roi ca(3) an-toan @W6.
0 prod-code, 0 migration, 0 FE, 0 test-change.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
W0.1 .gitattributes theo CLASS (khong va theo duoi-file-vua-can):
- `* text=auto eol=lf` = san chung. core.autocrlf=true @system lat LF->CRLF luc checkout;
attr nay ep blob LF + worktree LF, DOC-LAP autocrlf.
- Khai binary TUONG-MINH 13 duoi (zip/exe/dll/docx/xlsx/pptx/pdf/png/jpg/jpeg/ico/woff/woff2)
thay vi pho-thac heuristic NUL-byte-8000-dau: .docx "gay" co the lot thanh text -> mangle
OOXML -> hong file KHONG cuu duoc. Do that: repo co 19 binary (12 docx + 6 png + 1 xlsx).
- .svg = XML -> CO Y giu text. Giu 2 rule cu (broadcasts/** + *.sh) tuong-minh.
- Fault-inject chung rule CO RANG: go `*.docx binary` -> git coi .docx la `text: auto` (nguy
hiem that); khoi phuc -> `text: unset`. 19/19 binary co attr/-text.
- Acceptance PASS: agents/reviewer.md unspecified -> text:auto eol:lf.
W0.2 scoped-only (vacuous, KHAI THAT):
- scope-gate (agents+commands+skills) = 0 DA XANH SAN truoc khi lam gi -> KHONG tinh la thanh-tuu.
- repo-wide 188 (131 Migrations + 57 con lai) = INFORM-only. CAM mass rm+checkout phien nay.
- `git add --renormalize --dry-run .` = 0 file dirty; `git diff --cached --stat` = rong.
W0.3 hook rebase-interlock (anh ky S119 fix#8b = TRONG KHUNG, khong can adap-request):
- wal-flush.ps1: `if (Test-Path .git/rebase-merge -or .git/rebase-apply) { exit 0 }`.
- Dat SAU Set-Location $root, KHONG phai dau file: dat truoc thi Test-Path soi nham CWD.
- Chung RANG 2 CHIEU tren cay tam: (a) khong rebase-state -> hook VAN commit (guard khong
over-fire, WAL persist con song); (b) co rebase-state -> 0 commit, exit 0, worktree GIU dirty.
- Pure-ASCII giu nguyen (gotcha #30). Do lai bang tr sau khi phat hien `grep -P` false-pass
(loi locale -> output rong -> wc -l dem 0 = grep CHET, khong phai sach).
FIX #3-bis (MOI, ghi vao v3-PATCH) - dieu-kien re nhanh W0.3 test SAI THU:
- v2:92 re nhanh bang `NONWAL==0`; luat fix#3(c) noi phai test "wal: o DAY range". Hai thu khac nhau.
- Fault-inject 4 cay tam chung diem re o ca2 (shape base|wal:|[CLAUDE], NONWAL=1, day=wal:):
v2 -> nhanh-B REBASE; v3bis -> reset--soft. Chay that nhanh-B tren ca2: REBASE-EXIT=0 KHONG
crash, nhung commit gop THUA KE message "wal: flush 1" -> push-guard n=1 -> chan push ->
re-squash cung logic -> van "wal:" -> STOP VINH VIEN. Deadlock XAC NHAN bang thuc nghiem.
- +ca(0) MOI v2/v3 khong liet: K=0 range RONG (S119 da push 4727d16) -> NO-OP commit thang.
- 4 ca: (0) K=0 NO-OP · (1) day=wal: NONWAL=0 · (2) day=wal: NONWAL>0 -> (1)+(2) CUNG xu-ly
reset--soft origin/main CAM rebase · (3) day=commit-thuong -> rebase+fixup OK.
- Ca fire hom nay = ca(0). Commit-chot nay dat day range = commit thuong -> moi wal: sinh sau
deu roi vao ca(3) an-toan. Dung y do fix#3(a).
WAL reconcile (/tiep S120): ground-truth thang WAL 3 cho - (1) 7 broadcast "UNTRACKED co y"
da tracked+pushed trong 4727d16, W0.3 khong con viec gop; (2) "K troi 10->11" -> thuc te K=0
range RONG; (3) fix#8 tick mau-thuan -> owner-decisions xac nhan DA KY, gate-blocker=0.
0 prod-code, 0 migration, 0 FE, 0 test-change.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>