You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Own the downloader/UI adapter, router_cache.rs integration, bounded download operation progress and cache deletion tests. Existing downloader owns transport, filters, completeness and store containment; no separate shell downloader. Coordinator owner retains lifecycle/event types and shared locks.
Required behavior
Accept explicit public HuggingFace repo ID and optional revision, not arbitrary URL/local path. Resolve metadata/revision once and pin the download to that immutable commit; carry revision through existing downloader rather than inventing a different cache layout. Display expected destination and known bytes before transfer; unknown size remains unknown. Never execute remote modeling code.
Use fixed configured store and current offline policy; no requests on catalog browsing. Honor configured offline mode with a typed disabled reason. Private/gated repos return actionable unsupported/auth-required guidance without a token entry form in v1. Do not silently read/browser-persist Hub credentials.
Reuse download hooks but expose the common operation ID, monotonic received bytes, optional total/rate and real terminal result. Start with one active transfer and a bounded queue per server; no busy polling or network under pool locks. Duplicate repo/revision requests deduplicate; immutable revision mismatch must not overwrite a loaded model.
Cancel is cooperative and becomes terminal only after writer exit; preserve or clean partial data under an explicit policy. Interrupted/incomplete snapshots never become runnable because config.json happened to arrive first. Publish completion atomically after existing completeness validation; define retry/resume and server-restart reconciliation.
Cache deletion is a separate confirmed operation, never ordinary unload. Enforce managed-cache source, recheck canonical containment and revision immediately before deletion, refuse busy/loading/downloading models until drained/cancelled, and report actual disk deletion result. Preserve user models-dir/preset files, shared/external artifacts and active download targets.
Acceptance criteria
Fake HTTP/downloader tests cover valid download, bad repo/revision, gated/404, offline, timeout, disconnect, disk full, checksum/completeness failure, cancel/retry, restart, duplicate action and bounded queue saturation.
Test symlink swap/traversal/owner-name sanitization and removal races; cancellation cannot publish ready and deletion cannot race a writer or streaming provider.
One opt-in real public small-checkpoint download completes into the configured store, appears once, loads and generates; record repo+revision. CI hermetic tests do not require external network or GPU.
Existing compatibility download/removal endpoints call the same primitives and preserve their wire schema; UI-specific 202/progress semantics stay in the versioned adapter.
Parent / dependencies
Parent: #1834. Depends on #1835, #1839, #1840.
Ownership
Own the downloader/UI adapter,
router_cache.rsintegration, bounded download operation progress and cache deletion tests. Existing downloader owns transport, filters, completeness and store containment; no separate shell downloader. Coordinator owner retains lifecycle/event types and shared locks.Required behavior
Acceptance criteria