From 51c213c371533b151244d280ee2525fd9bc7159a Mon Sep 17 00:00:00 2001 From: Renato Costa Date: Wed, 12 Oct 2022 15:23:25 -0400 Subject: [PATCH] roachprod: log Get failures in roachtests `roachprod.Get` and `roachprod.Put` behaved differently when it comes to logging of errors: the former would not log errors found while running `scp` if there was a file backing the logger, while the latter would. However, there is no reason for this difference, and it was probably an oversight introduced in an old, really large PR (#74223). This commit makes behavior consistent in both calls and should allow us to see `Get` errors in logs, especially important in `roachtest` failures. Epic: None. Release note: None. --- pkg/roachprod/install/cluster_synced.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/roachprod/install/cluster_synced.go b/pkg/roachprod/install/cluster_synced.go index 6a87c51689d3..c65005397392 100644 --- a/pkg/roachprod/install/cluster_synced.go +++ b/pkg/roachprod/install/cluster_synced.go @@ -2021,7 +2021,7 @@ func (c *SyncedCluster) Get(l *logger.Logger, nodes Nodes, src, dest string) err } } - if config.Quiet && l.File == nil { + if config.Quiet && l.File != nil { l.Printf("\n") linesMu.Lock() for i := range lines {