Open Audacia-RhysSmith opened 1 month ago
My two cents on each one:
Log
overloads take a LogLevel
parameter?My input on each one too:
.editorconfig
Handler
or Service
in this case?If log messages contains an interpolated string, should use template message (FormatableString in C#)
🟢 worth a very quick PR into Audacia.CodeAnalysis? Maybe at the same time as the logging standards are merged?
Every command or service injects ILogger
🟡 less convinced by this, do we want all of our commands/services to inject a logger?
Every log message should have more 3 words? (thinking behind is that 3 words isnt descriptive enough)
🟢 could be a char check - but agree with this in principle
Check for duplicate log statements
🟡 within the same method / class? For me this isn't a common enough issue, and doesn't catch scenarios like when copy/pasting from another area
Violation for if the amount of log statements if greater than the amount of "functionality" lines. If there was 5 lines in a method, should there be 8 lines of logging (thinking is this would violate clear and concise logging)
🟢 yeah why not
Created a PR to propose changes for points 1 and 2 - would appreciate any feedback
https://github.com/audaciaconsulting/Audacia.CodeAnalysis/pull/36