Suggest FlakeHub Cache when hit by 429
This commit is contained in:
parent
215dc0d8e9
commit
b9f89bd546
|
@ -624,10 +624,16 @@ impl AtomicCircuitBreaker for AtomicBool {
|
||||||
fn check_err(&self, e: &Error) {
|
fn check_err(&self, e: &Error) {
|
||||||
if let Error::ApiError {
|
if let Error::ApiError {
|
||||||
status: reqwest::StatusCode::TOO_MANY_REQUESTS,
|
status: reqwest::StatusCode::TOO_MANY_REQUESTS,
|
||||||
info: ref _info,
|
..
|
||||||
} = e
|
} = e
|
||||||
{
|
{
|
||||||
tracing::info!("Disabling GitHub Actions Cache due to 429: Too Many Requests");
|
tracing::info!("Disabling GitHub Actions Cache due to 429: Too Many Requests");
|
||||||
|
let msg = "\
|
||||||
|
Magic Nix Cache has exceeded GitHub Actions Cache's rate limit. \
|
||||||
|
Save more time and seamlessly share the builds across your team with FlakeHub Cache. \
|
||||||
|
See: https://flakehub.com/pricing\
|
||||||
|
";
|
||||||
|
println!("::notice::{msg}");
|
||||||
self.store(true, Ordering::Relaxed);
|
self.store(true, Ordering::Relaxed);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue