From: Peter Amstutz Date: Tue, 20 Dec 2016 16:10:56 +0000 (-0500) Subject: 10497: crunch-run records logs even when container is cancelled. X-Git-Tag: 1.1.0~525^2 X-Git-Url: https://git.arvados.org/arvados.git/commitdiff_plain/3beb006fd2c533a192379c9730a3a730c5493b90 10497: crunch-run records logs even when container is cancelled. --- diff --git a/services/crunch-run/crunchrun.go b/services/crunch-run/crunchrun.go index ebee1a8f1e..e13033edb3 100644 --- a/services/crunch-run/crunchrun.go +++ b/services/crunch-run/crunchrun.go @@ -751,10 +751,10 @@ func (runner *ContainerRunner) ContainerToken() (string, error) { func (runner *ContainerRunner) UpdateContainerFinal() error { update := arvadosclient.Dict{} update["state"] = runner.finalState + if runner.LogsPDH != nil { + update["log"] = *runner.LogsPDH + } if runner.finalState == "Complete" { - if runner.LogsPDH != nil { - update["log"] = *runner.LogsPDH - } if runner.ExitCode != nil { update["exit_code"] = *runner.ExitCode }