docs(dn): record lifecycle containment evidence

This commit is contained in:
DEls 2026-09-18 19:32:32 +02:00
parent 05c9b6b8f0
commit ba5288465e

View file

@ -81,6 +81,32 @@ file, 11 tests.
`git diff --check` — passed.
Fix round 3 implementation commit:
`05c9b6b8f084ac71e9cc462d521b1c48539855db fix(dn): contain bulk batch lifecycle`
## Fix round 3 evidence
- New batches are created as `status: "needs_attention"` and
`stage: "preparing"`, so a surviving batch is never processable while
`source_count` persistence is unresolved. Only the successful final update
sets `source_count`, `status: "inbox"`, and `stage: "queued"`.
- If that final update fails, deletion is attempted. If deletion also fails,
the response/log report both failures and the surviving batch remains in its
initial non-processable state.
- In-request hash grouping now reports deferred copies as duplicates only when
the primary source write succeeds; if it fails, all grouped copies report
the same visible source-write error.
Exact fix-round 3 verification:
`npx vitest run src/app/api/delivery-notes/upload/route.test.ts` — passed, 1
file, 15 tests.
`npm run typecheck` — passed (`tsc --noEmit`).
`git diff --check` — passed.
## Fix round 2 evidence
- Oversized single-file validation now returns the exact legacy payload with