gabriel / musehub public
feat BREAKING task/wire-fetch-phase2 #1 / 1
AI Agent gabriel · 121 days ago · May 16, 2026 · Diff

feat: Phase 2 fetch protocol — single presigned URL, 503 on unindexed objects

- wire_fetch_mpack rewritten to Phase 2 spec: POST /fetch returns {mpack_url, mpack_id, commit_count, object_count}; client GETs mpack directly from MinIO - Step 3 checks musehub_mpack_index coverage; raises FetchNotIndexedError (503) if any object is not yet indexed — no loose-object fallback - Step 4 loads bytes via content_cache first, MinIO fallback - Step 6 stores mpack ephemerally and presigns GET URL; TTL cleanup via ensure_future - FetchNotIndexedError caught in route handler → 503 + Retry-After: 60 - test_cdn5 deleted: tested pack_urls/pack_fetch path that no longer exists - test_lf2 updated: stub backend gains presign_get, objects indexed in DB, assertion checks mpack_id is not None and is sha256-prefixed

sha256:d8b4340f6da72076c5e3f7f346f584117dc31d2c567af15ad772c5e3cb04273e sha
+4 ~19 −5 symbols
sha256:8941681b818cf6e79228f67ae6cbfb80ab13d3bfd1f9a41287c3cc1d30bd8b2a snapshot
+4
symbols added
~19
symbols modified
−5
symbols removed
0
dead code introduced
Semantic Changes 28 symbols
~ musehub/services/musehub_wire.py .py 2 symbols added, 4 symbols removed, 2 symbols modified
apply_delta import import apply_delta L84–84
decompress_if_needed import import decompress_if_needed L84–84
decompress_zlib import import decompress_zlib L84–84
decompress_zstd import import decompress_zstd L84–84
+ FetchNotIndexedError class class FetchNotIndexedError L129–137
+ __init__ method method __init__ L135–137
~ tests/test_cdn_reads_phase5.py .py 1 symbol removed
test_cdn5_wire_fetch_mpack_pack_urls_use_cdn function async_function test_cdn5_wire_fetch_mpack_pack_urls_use_cdn L244–279
~ tests/test_ltier_fetch_regression.py .py 1 symbol added, 3 symbols modified
← Older Oldest on task/wire-fetch-phase2
All commits
Newer → Latest on task/wire-fetch-phase2

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