1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-24 22:11:15 +02:00

silence logs because it gets overwhelming

This commit is contained in:
Philip Wilk 2025-06-02 02:57:52 +01:00
parent 29f9facf76
commit 245bc5d547
No known key found for this signature in database
2 changed files with 7 additions and 8 deletions

View file

@ -60,10 +60,6 @@ Goal::Co PathSubstitutionGoal::init()
for (const auto & sub : subs) {
trace("trying next substituter");
// If sub is not first, previous one must have failed, so warn
if (&sub != &subs.front()) {
warn("trying next substituter, '%s'", sub->getUri());
}
cleanup();
@ -88,15 +84,16 @@ Goal::Co PathSubstitutionGoal::init()
try {
// FIXME: make async
info = sub->queryPathInfo(path);
// Because the path doesn't exist
} catch (InvalidPath &) {
continue;
// Because the substituter has failed recently
} catch (SubstituterDisabled & e) {
/* This is also VERY spammy
warn(
"Substituter '%s' was disabled when getting info for path '%s'",
sub->getUri(),
sub->printStorePath(path));
*/
continue;
// Any other error
} catch (Error & e) {

View file

@ -559,15 +559,17 @@ void Store::querySubstitutablePathInfos(const StorePathCAMap & paths, Substituta
} catch (SubstituterDisabled &) {
} catch (Error & e) {
// if last substituter, THEN log error and throw, otherwise warn
if (&sub == &substituters.back() && settings.tryFallback) {
if (&sub == &substituters.back() && !settings.tryFallback) {
logError(e.info());
throw;
} else {
warn(
"Unable to download '%s' from subsituter '%s'\n%s",
/* This gets VERY spammy
warn( "Unable to download '%s' from subsituter '%s'\n%s",
sub->printStorePath(subPath),
sub->getUri(),
e.message());
*/
continue;
}
}
}