ref(maven): Improve logging for maven target - #275
Merged
Conversation
Most of the packages aren't supposed to be BOM files, and logging this may give the impression that something is missing when it's not.
iker-barriocanal
requested review from
AbhiPrasad and
vladanpaunovic
and removed request for
a team
August 17, 2021 09:51
AbhiPrasad
reviewed
Aug 17, 2021
Comment on lines
+417
to
+418
| if (output) { | ||
| if (output.length === 0) { |
Contributor
There was a problem hiding this comment.
We can combine this conditional.
| private logCmdOutput(output: Buffer | undefined): void { | ||
| if (output) { | ||
| if (output.length === 0) { | ||
| this.logger.debug(`The command didn't have any output.`); |
Contributor
There was a problem hiding this comment.
Hard to know what the command is from this statement, would be helpful to have some details about the command
BYK
requested changes
Aug 17, 2021
| : `${moduleName}.jar`; | ||
| } | ||
|
|
||
| private logCmdOutput(output: Buffer | undefined): void { |
Member
There was a problem hiding this comment.
You shouldn't need any of this as spawnProcess does it underneath:
Lines 174 to 182 in a015c79
BYK
requested changes
Aug 17, 2021
BYK
left a comment
Member
There was a problem hiding this comment.
I don't understand the motivation behind the this.logger.level >= LogLevel.Debug condition.
spawnProcess already logs with level info if this is true at all times. If we want to see the output for debugging purposes, we can always set the logging level to trace for that specific session, right?
| this.mavenConfig.mavenSettingsPath, | ||
| ], | ||
| {}, | ||
| { showStdout: this.logger.level >= LogLevel.Debug } |
BYK
approved these changes
Aug 18, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
trace.