Closed Luolired closed 5 years ago
What is your flask version? How did you install the flask? (pip, etc.)
Flask (0.8) Ubuntu 12.04.5 LTS \n \l
def close_connection(exception): db = getattr(g, '_database', None) if db is not None: db.close()
Success OK
Please reopen with additional details if this is still a problem for new version.
@Luolired I don't really see how commenting out the problematic line is a solution. Is a bug fixed when you delete the codebase it's in?
root@Soc:/home/lizx/cesi# vi /etc/cesi.conf
[node:220] username = soc_web password = XXXX host = 10.1.101.220 port = 9001
[node:]
;username =
;password =
;host =
;port =
[environment:soc_web] members = 220
[cesi] database =/home/lizx/cesi/userinfo.db activity_log =/home/lizx/cesi/cesi_activity.log host = 0.0.0.0
root@Soc:/home/lizx/cesi# python cesi/web.py Traceback (most recent call last): File "cesi/web.py", line 27, in
@app.teardown_appcontext
AttributeError: 'Flask' object has no attribute 'teardown_appcontext'