mirror of
https://github.com/NixOS/nix
synced 2025-07-05 20:41:47 +02:00
Add a structured log message for FOD hash mismatches
This commit is contained in:
parent
1212b1fbfe
commit
8ef94c1114
2 changed files with 7 additions and 0 deletions
|
@ -2656,6 +2656,12 @@ SingleDrvOutputs LocalDerivationGoal::registerOutputs()
|
||||||
worker.store.printStorePath(drvPath),
|
worker.store.printStorePath(drvPath),
|
||||||
wanted.to_string(HashFormat::SRI, true),
|
wanted.to_string(HashFormat::SRI, true),
|
||||||
got.to_string(HashFormat::SRI, true)));
|
got.to_string(HashFormat::SRI, true)));
|
||||||
|
// FIXME: put this in BuildResult and log that as JSON.
|
||||||
|
act->result(resHashMismatch,
|
||||||
|
{worker.store.printStorePath(drvPath),
|
||||||
|
wanted.to_string(HashFormat::SRI, true),
|
||||||
|
got.to_string(HashFormat::SRI, true)
|
||||||
|
});
|
||||||
}
|
}
|
||||||
if (!newInfo0.references.empty()) {
|
if (!newInfo0.references.empty()) {
|
||||||
auto numViolations = newInfo.references.size();
|
auto numViolations = newInfo.references.size();
|
||||||
|
|
|
@ -36,6 +36,7 @@ typedef enum {
|
||||||
resSetExpected = 106,
|
resSetExpected = 106,
|
||||||
resPostBuildLogLine = 107,
|
resPostBuildLogLine = 107,
|
||||||
resFetchStatus = 108,
|
resFetchStatus = 108,
|
||||||
|
resHashMismatch = 109,
|
||||||
} ResultType;
|
} ResultType;
|
||||||
|
|
||||||
typedef uint64_t ActivityId;
|
typedef uint64_t ActivityId;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue