Added setting python.logging.level which carries the logging level value the extension will log at - #11698
Conversation
bc33279 to
90c9163
Compare
Codecov Report
@@ Coverage Diff @@
## logging-changes-and-drop-old-debugger #11698 +/- ##
========================================================================
Coverage ? 60.67%
========================================================================
Files ? 629
Lines ? 34040
Branches ? 4798
========================================================================
Hits ? 20655
Misses ? 12375
Partials ? 1010 Continue to review full report at Codecov.
|
90c9163 to
c654ea5
Compare
There was a problem hiding this comment.
How does this PR relate to #11695? It seems like there is some overlap. It isn't clear why this PR needs to be based on the other.
Eric Snow (ericsnowcurrently)
left a comment
There was a problem hiding this comment.
A few more comments.
7a5dac4 to
b388197
Compare
Kim-Adeline Miguel (kimadeline)
left a comment
There was a problem hiding this comment.
This PR look alright to me, but I have no context on what would make sense or not, I'll let Eric Snow (@ericsnowcurrently) be the judge of that 🙂
b388197 to
6a38567
Compare
Eric Snow (ericsnowcurrently)
left a comment
There was a problem hiding this comment.
Thanks for making those changes. It's looking good. I've left some minor comments, with a number of them repeating the same recommendation regarding "Off". So I think this is close. Thanks again!
|
Eric Snow (@ericsnowcurrently) Having export function resolveLevelName(
level: LogLevel,
// Default to configLevels.
levels?: winston.config.AbstractConfigSetLevels
): string | undefined {
if (levels === undefined) {
return getLevelName(level);
} else if (levels === configLevels) {
return getLevelName(level);
} else if (levels === winston.config.npm.levels) {
return npmLogLevelMap[level];
} else {
return undefined;
}
}Here |
Eric Snow (ericsnowcurrently)
left a comment
There was a problem hiding this comment.
At this point I only have one thing that I think should be done slightly differently: use a different sentinel value (than undefined) in the PythonSettings to say "disable logging".
Otherwise the changes look good. Thanks for your patience. FYI, the other two comments are just minor changes (formatting and expanding a comment).
I'm fine with not adding (Also, it may make sense to have a separate setting to disable logging, rather than overloading |
Eric Snow (ericsnowcurrently)
left a comment
There was a problem hiding this comment.
LGTM
Thanks for working it out. 😄
|
Kudos, SonarCloud Quality Gate passed!
|
2db900c
into
microsoft:logging-changes-and-drop-old-debugger
…value the extension will log at (microsoft#11698) * Added setting * Code reviews * Fix unit tests * Code reviews * Put config.level back * Added commnet * Code review * More code reviews * Fix tests
…value the extension will log at (microsoft#11698) * Added setting * Code reviews * Fix unit tests * Code reviews * Put config.level back * Added commnet * Code review * More code reviews * Fix tests
…value the extension will log at (microsoft#11698) * Added setting * Code reviews * Fix unit tests * Code reviews * Put config.level back * Added commnet * Code review * More code reviews * Fix tests
For #11699
This PR is based on #11695
package-lock.jsonhas been regenerated by runningnpm install(if dependencies have changed).