Update Log Policy
This commit is contained in:
parent
09925a8467
commit
45fd587741
1
.gitignore
vendored
1
.gitignore
vendored
@ -35,3 +35,4 @@ __pycache__/IDManager.cpython-39.pyc
|
||||
*.pyc
|
||||
*.pyc
|
||||
questionare.csv
|
||||
log.txt
|
||||
|
6
main.py
6
main.py
@ -6,6 +6,12 @@ import uuid
|
||||
from IDManager import idManager
|
||||
|
||||
from flask import Flask, render_template, request, redirect, url_for, session
|
||||
import logging
|
||||
|
||||
# 设置logging模块
|
||||
logging.basicConfig(filename='log.txt', level=logging.DEBUG)
|
||||
# 将print输出重定向到logging模块
|
||||
print = logging.getLogger().info
|
||||
|
||||
app = Flask(__name__, static_folder='')
|
||||
idm = idManager()
|
||||
|
Loading…
Reference in New Issue
Block a user