You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are still occasions where print has remained and should be replaced by the logger.*. Some can remain, e.g. the notification about daemonizing or missing dependencies. This issue will be updated as I find more locations.
@PeterSurda can we be clear about scope and expected results please? Some thoughts that come to mind:
Increase scope to use the opportunity of going through the code thoroughly with a mind on logging
Test various logging configurations (which?), remove config cruft, document what to expect out of logging, maybe testing further logging config examples (rsyslog, elasticsearch?)
Ensure log levels are appropriate and sent to stdout/stderr as appropriate
Consider consolidating the number of log levels in use
Consider any refactoring or standardisation of logging code (e.g. avoid code repetition, circular imports)
Consider whether a log entry is actually required; maybe the point of a log entry is to watch out for a condition that better testing could have guarded against
Ensure consistent log message style (tenses, first/third sing/pl person etc.)
Change print statements to use the logger
Implement tests around logging (critical examples?)
Quick check of the scale of this task:
12 logger.exception() calls
12 logger.fatal() calls
13 logger.critical() calls
20 logger.warning() calls
167 logger.info() calls
185 logger.debug() calls
467 (approx) print statements
Activity
coffeedogs commentedon Oct 19, 2018
@PeterSurda can we be clear about scope and expected results please? Some thoughts that come to mind:
Quick check of the scale of this task:
12
logger.exception()calls12
logger.fatal()calls13
logger.critical()calls20
logger.warning()calls167
logger.info()calls185
logger.debug()calls467 (approx)
printstatementsnavjotcis commentedon Sep 22, 2020
I have removed the print statement of the api.py module.
#1673