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
{{ message }}
Repository navigation
Browse API still serves offline hosted and group repositories (#73 follow-up) #120
Severity: Low (only readers who may read the repository anyway). Blocks the first release: no. Found in the 1.0.0 release review.
What
#73 made an offline hosted or group repository answer 503 on /v3 (dispatch.rs). The browse API has no such check:
GET /browse/packages (search_packages) lists the packages of an offline hosted or group repository;
GET /browse/packages/{repo}/{id} (package_detail) returns its versions and dependency metadata.
HostedRepo has no offline check of its own; only ProxyRepo and group members check it. During a maintenance window the web UI therefore keeps showing what the feed refuses to serve.
Fix
Decide what "Online (serve requests)" means for the web UI, then make browse match it:
skip offline hosted and group repositories in search_packages, and answer 503 with Retry-After in package_detail after the read check, as dispatch does; or
keep browsing them, and have the UI badge the repository "offline" and say so in the switch's help text.
Tests to add
Browse search and detail on an offline hosted repository and on an offline group behave as decided; an offline proxy still shows what it cached.
Activity