diff -r 89d235bcbbf3 -r 986ee928a866 annot-server/webapp/__init__.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/annot-server/webapp/__init__.py Tue Oct 14 05:07:37 2014 +0200 @@ -0,0 +1,23 @@ +# +# See LICENCE for detail +# Copyright (c) 2014 IRI +# + +import uuid +import json + +from flask import Flask + +import config +import database + +app = Flask(__name__) +app.secret_key = str(uuid.uuid4()) +app.debug = config.DEBUG +app.config.from_object(config) + +import webapp.views + +@app.teardown_appcontext +def shutdown_session(exception=None): + database.db_session.remove()