gabriel / musehub public
feat BREAKING task/repair-snapshot-endpoint #1 / 1
gabriel · 67 days ago · Apr 14, 2026 · Diff

feat: repair-snapshot endpoint — force-overwrite corrupt snapshot manifests

Adds POST /{owner}/{slug}/repair-snapshot to the wire protocol.

Unlike the push path (ON CONFLICT DO NOTHING), this endpoint uses ON CONFLICT DO UPDATE so a snapshot stored with an empty manifest_blob can be corrected without deleting the row first.

- wire_repair_snapshot() in musehub_wire.py: verifies compute_snapshot_id(manifest, directories) == snapshot_id before writing, same auth gate as repair-object (owner/write/admin only). - compute_snapshot_id() in muse_cli/snapshot.py: updated to accept optional directories list, matching muse.core.snapshot's behaviour (directory renames now produce distinct snapshot IDs server-side too). - Route wired in wire.py alongside repair-object.

sha256:eed876d51ab43eddcd4bb00087817c1b2a0ee6db60778b05f8378e07fc01f310 sha
sha256:617811ca0dd60dc214e75fa35fb6cab96ab07c80756478ed3542297d8d9d7d94 snapshot
← Older Oldest on task/repair-snapshot-endpoint
All commits
Newer → Latest on task/repair-snapshot-endpoint

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:eed876d51ab43eddcd4bb00087817c1b2a0ee6db60778b05f8378e07fc01f310 --body "your comment"