Python Forum
Python Forum
>
Python Coding
>
Web Scraping & Web Development
> Redirecting all Flask logs
Full Version:
Redirecting all Flask logs
You're currently viewing a stripped down version of our content.
View the full version
with proper formatting.
georgelza
Apr-18-2018, 12:48 PM
Hi all
Is it possible to redirect all FLASK logs to syslog (or a normal text log file) aka when run_server(debug=true) is specified
G
thomasp
Nov-21-2018, 01:52 PM
Flask uses the logging module:
http://flask.pocoo.org/docs/1.0/logging/
It should be possible to add a custom handler, for example:
https://docs.python.org/2/library/loggin...loghandler
Python Forum
>
Python Coding
>
Web Scraping & Web Development
> Redirecting all Flask logs