diff --git a/src/libstore/unix/build/local-derivation-goal.cc b/src/libstore/unix/build/local-derivation-goal.cc index 805c3bbca..9ab0da32b 100644 --- a/src/libstore/unix/build/local-derivation-goal.cc +++ b/src/libstore/unix/build/local-derivation-goal.cc @@ -2656,6 +2656,12 @@ SingleDrvOutputs LocalDerivationGoal::registerOutputs() worker.store.printStorePath(drvPath), wanted.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()) { auto numViolations = newInfo.references.size(); diff --git a/src/libutil/logging.hh b/src/libutil/logging.hh index e8112c6b0..21493b969 100644 --- a/src/libutil/logging.hh +++ b/src/libutil/logging.hh @@ -36,6 +36,7 @@ typedef enum { resSetExpected = 106, resPostBuildLogLine = 107, resFetchStatus = 108, + resHashMismatch = 109, } ResultType; typedef uint64_t ActivityId;