gabriel / musehub public
fix patch main #11 / 32
AI Agent gabriel · 32 days ago · May 9, 2026 · Diff

fix: heal ghost objects in _store_batch — verify MinIO presence before skipping

_store_batch used a DB-only existence check to decide whether to PUT to MinIO. A ghost (DB row present, MinIO bytes absent) would be silently skipped on every future push, making it permanent.

Fix: call backend.exists() for each DB-present object before skipping. If storage says missing, treat it as new and issue the PUT — self-healing. Ghosts are rare in steady state so the extra HEAD requests are negligible.

Tests I5a (structural) and I5b (behavioural) pin the invariant.

sha256:6195ecc8910bbcf07ea5a8c313c3500389d907f3d687426adfdfc2c3f6c4063a sha
sha256:28a49fb180be4fbdde0e924325dccce565f02b177ec150f15eeb50c35dbe8173 snapshot

0 comments

No comments yet. Be the first to start the discussion.

To add a comment, use the Muse CLI: muse hub commit comment sha256:6195ecc8910bbcf07ea5a8c313c3500389d907f3d687426adfdfc2c3f6c4063a --body "your comment"