I would like to log the module and classname by default in log messages from my request handlers.
The usual way to do this seems to be to set a custom format string by calling logging.basicConfig
, but this can only be called once and has already been called by the time my code runs.
Another method is to create a new log Handler
which can be passed a new log Formatter
, but this doesn't seem right as I want to use the existing log handler that App Engine has installed.
What is the right way to have extra information added to all log messages in python App Engine, but otherwise use the existing log format and sink?