Undocumented
Variable | default_handler |
Undocumented |
Function | create_logger |
Get the Flask app's logger and configure it if needed. |
Function | has_level_handler |
Check if there is a handler in the logging chain that will handle the given logger's effective level . |
Function | wsgi_errors_stream |
Find the most appropriate error stream for the application. If a request is active, log to wsgi.errors, otherwise use sys.stderr. |
Get the Flask app's logger and configure it if needed.
The logger name will be the same as
app.import_name
.
When ~flask.Flask.debug
is enabled, set the logger level to
logging.DEBUG
if it is not set.
If there is no handler for the logger's effective level, add a
~logging.StreamHandler
for
~flask.logging.wsgi_errors_stream
with a basic format.
Parameters | |
app:Flask | Undocumented |
Returns | |
logging.Logger | Undocumented |
effective level
.Parameters | |
logger:logging.Logger | Undocumented |
Returns | |
bool | Undocumented |
Find the most appropriate error stream for the application. If a request is active, log to wsgi.errors, otherwise use sys.stderr.
If you configure your own logging.StreamHandler
, you may want to
use this for the stream. If you are using file or dict configuration and
can't import this directly, you can refer to it as
ext://flask.logging.wsgi_errors_stream.
Returns | |
t.TextIO | Undocumented |