-
Notifications
You must be signed in to change notification settings - Fork 1
Description
If for no other reason than Claude being convinced that must be a log.warning() :)
Context
basic_bot.commons.log module currently provides .debug() and .info() and .error() messages. Showing of debug messages in the stdout are conditioned on being in "development" or "test" BB_ENV or if the BB_LOG_DEBUG is truthy
The only difference between .info and .error currently is the message prefix in the line output being "INFO: " and "ERROR: ".
The timestamps are intended to be sortable and easily readable.
Why are we not using the Python logging builtin? 🤷 I do have a reason, but it's mostly an ignorant one. I'll start with the proposition that logging should be dirt easy to use and configure, and, given that we live in a Docker container world, should by default direct its output to stdout and stderr where container management tools expect to look for application-level logging?
Task
- Just add a .warning() function for now with same timestamp format, a message prefix "WARN: "
- There is no need for conditional display; always show.
- use stdout