Development record
four bespoke LOCK_EX flock loops remain (memory/writer.go, intent/create.go, spec/store.go, history/store.go) now that fsutil.WithFileLock is the canonical inter-process lock primitive; consolidate them onto it (one-canonical-primitive) — pre-existing, no defect, pure debt
issueresolvedminoriss-129
four bespoke LOCK_EX flock loops remain (memory/writer.go, intent/create.go, spec/store.go, history/store.go) now that fsutil.WithFileLock is the canonical inter-process lock primitive; consolidate them onto it (one-canonical-primitive) — pre-existing, no defect, pure debt
Remedy grounds (2026-09-29)
- Confirmed at the base: five sites call syscall.Flock directly (decide.go:283, memory/writer.go:77, spec/store.go:326, intent/create.go:673, history/store.go:156), and history/store.go blocks without a timeout.
- The detector test keeps a sixth site from appearing. Rejected: forcing directory locks onto the lock-file primitive, which the deferral records WithFileLock cannot take.
Grounds
- pursued: we expect every inter-process lock in the tree to go through one of fsutil's two primitives, with each site's refusal and budget kept; a production flock outside internal/fsutil, or a site test that went red, would show it wrong
Frontmatter
| id | iss-129 |
|---|---|
| type | issue |
| lifecycle | resolved |
| severity | minor |
.abcd/work/issues/resolved/iss-129-consolidate-bespoke-flock-loops.md
open on GitHub ↗ · commit history ↗
mentions2
- dcn-26082600000000052026-08-26 — Bug-hunt round 8 (bughunt-b): baseline green after unshallowing
- iss-2608261133210491the memory store-lock guard tests mode AND S_IFREG nonzero instead of masking with S_IFMT, so its regular-file assertion also accepts symlink and socket modes; dead defence shielded by O_NOFOLLOW, fold into the iss-129 flock consolidation