docs(01-02): complete body-size-limits and test-hardening plan

- 01-02-SUMMARY.md: plan completion summary with deviations
- STATE.md: advanced plan position, added decisions, updated metrics
- ROADMAP.md: phase 01 marked complete (2/2 plans)
- REQUIREMENTS.md: DATA-03 and DATA-04 marked complete
This commit is contained in:
2026-03-23 21:26:02 +01:00
parent 7bdfc5ffec
commit 03c3d5d6d7
4 changed files with 142 additions and 12 deletions

View File

@@ -2,14 +2,14 @@
gsd_state_version: 1.0
milestone: v1.0
milestone_name: milestone
status: Ready to execute
stopped_at: Completed 01-01-PLAN.md (UPSERT + FK enforcement)
last_updated: "2026-03-23T20:16:27.362Z"
status: Phase complete — ready for verification
stopped_at: Completed 01-02-PLAN.md (body size limits + test hardening)
last_updated: "2026-03-23T20:25:50.296Z"
progress:
total_phases: 4
completed_phases: 0
completed_phases: 1
total_plans: 2
completed_plans: 1
completed_plans: 2
---
# Project State
@@ -47,6 +47,7 @@ Plan: 2 of 2
*Updated after each plan completion*
| Phase 01 P01 | 2 | 2 tasks | 2 files |
| Phase 01-data-integrity P02 | 7 | 2 tasks | 2 files |
## Accumulated Context
@@ -61,6 +62,8 @@ Recent decisions affecting current work:
- `DATABASE_URL` present activates PostgreSQL; absent falls back to SQLite with `DB_PATH` — no separate `DB_DRIVER` variable
- [Phase 01]: Use named-column UPSERT (ON CONFLICT DO UPDATE) to preserve tag_assignments child rows on re-insert
- [Phase 01]: Enable PRAGMA foreign_keys = ON in InitDB() before DDL to activate ON DELETE CASCADE for tag deletion
- [Phase 01-data-integrity]: Use MaxBytesReader + errors.As(*http.MaxBytesError) per-handler (not middleware) for request body size limiting — consistent with no-middleware architecture
- [Phase 01-data-integrity]: Oversized body tests need valid JSON prefix so decoder reads past 1MB limit; all-x bytes fail at byte 1 before MaxBytesReader triggers
### Pending Todos
@@ -73,6 +76,6 @@ None yet.
## Session Continuity
Last session: 2026-03-23T20:16:27.360Z
Stopped at: Completed 01-01-PLAN.md (UPSERT + FK enforcement)
Last session: 2026-03-23T20:25:50.294Z
Stopped at: Completed 01-02-PLAN.md (body size limits + test hardening)
Resume file: None