From 80691a39f50917e63da3a2743f0c0a39ea60e443 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 22 Apr 2009 14:41:12 +0000 Subject: [PATCH] * Don't log redundant build steps in case of cached failures. --- src/script/hydra_build.pl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/script/hydra_build.pl b/src/script/hydra_build.pl index 555f0145..fa5ef015 100755 --- a/src/script/hydra_build.pl +++ b/src/script/hydra_build.pl @@ -96,7 +96,11 @@ sub doBuild { if ($buildSteps{$drvPathStep}) { my $step = $build->buildsteps->find({stepnr => $buildSteps{$drvPathStep}}) or die; $step->update({busy => 0, status => 1, errormsg => $errorMsg, stoptime => time}); - } else { + } + # Don't write a record if this derivation already + # failed previously. This can happen if this is a + # restarted build. + elsif (scalar $build->buildsteps->search({drvpath => $drvPathStep, type => 0, busy => 0, status => 1}) == 0) { $build->buildsteps->create( { stepnr => ($buildSteps{$drvPathStep} = $buildStepNr++) , type => 0 # = build