Skip to main content

retry_after_delay

Function retry_after_delay 

Source
pub fn retry_after_delay(message: &str) -> Option<Duration>
Expand description

Parse a Retry-After header value from cargo/registry output.

Cargo exposes registry failures through human-facing stderr/stdout rather than a structured HTTP response. When that text contains a Retry-After header, this returns the registry’s requested wait as a duration.