Skip to content

Commit

Permalink
log conda output (apache#588)
Browse files Browse the repository at this point in the history
## Upstream SPARK-XXXXX ticket and PR link (if not applicable, explain)
When running verbose conda commands, outputs via `log.info` are not being logged, but outputs with `logInfo` are. We also want to log the conda command in the case the verbosity flag is on (>0).
## What changes were proposed in this pull request?

Change the logging of the conda command to `logInfo` and log the command when the verbosity flag is on.

## How was this patch tested?

N/A.
  • Loading branch information
azarum authored and bulldozer-bot[bot] committed Aug 2, 2019
1 parent bf401d3 commit cd97fb1
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -177,12 +177,15 @@ final class CondaEnvironmentManager(condaBinaryPath: String,
BasicIO.processFully((redactCredentials _).andThen(line => {
out.append(line)
out.append(BasicIO.Newline)
if (verbosity > 0) {
logInfo(s"<conda> $line")
}
()
})),
BasicIO.processFully((redactCredentials _).andThen(line => {
err.append(line)
err.append(BasicIO.Newline)
log.info(s"<conda> $line")
logInfo(s"<conda> $line")
})))
val exitCode = command.run(collectErrOutToBuffer).exitValue()
if (exitCode != 0) {
Expand Down

0 comments on commit cd97fb1

Please sign in to comment.