Remove file logging

This commit is contained in:
elpatron68
2024-05-26 12:06:02 +02:00
parent 1d91505b50
commit 6abfe64fd4
2 changed files with 5 additions and 24 deletions

13
app.py
View File

@@ -95,13 +95,10 @@ def favicon():
'favicon.ico', mimetype='image/vnd.microsoft.icon') 'favicon.ico', mimetype='image/vnd.microsoft.icon')
if __name__ == "__main__": if __name__ == "__main__":
directory = './log' # directory = './log'
if not os.path.exists(directory): # if not os.path.exists(directory):
# Create the directory # # Create the directory
os.makedirs(directory) # os.makedirs(directory)
logger = logging.getLogger(__name__) logging.info('Starting erdbeerhannah v1.0.1')
logging.basicConfig(filename='./log/app.log', encoding='utf-8', level=logging.DEBUG)
logging.info('Starting erdbeerhannah v1.0')
app.run(debug=True, host='0.0.0.0') app.run(debug=True, host='0.0.0.0')

View File

@@ -1,16 +0,0 @@
INFO:root:Starting erdbeerhannah v1.0
INFO:werkzeug:WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
* Running on all addresses (0.0.0.0)
* Running on http://127.0.0.1:5000
* Running on http://192.168.177.24:5000
INFO:werkzeug:Press CTRL+C to quit
INFO:werkzeug: * Restarting with stat
INFO:root:Starting erdbeerhannah v1.0
WARNING:werkzeug: * Debugger is active!
INFO:werkzeug: * Debugger PIN: 213-823-308
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:06] "POST / HTTP/1.1" 200 -
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:06] "GET /favicon.ico HTTP/1.1" 304 -
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:07] "POST / HTTP/1.1" 200 -
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:08] "POST / HTTP/1.1" 200 -
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:13] "POST / HTTP/1.1" 200 -
INFO:werkzeug:192.168.177.24 - - [26/May/2024 11:45:19] "POST / HTTP/1.1" 200 -