Update: Uncomment db & remove patch_all
This commit is contained in:
parent
ac3236d9f8
commit
af41c64517
1 changed files with 3 additions and 4 deletions
|
|
@ -5,8 +5,7 @@ import sys
|
||||||
import os
|
import os
|
||||||
|
|
||||||
db = SQLAlchemy()
|
db = SQLAlchemy()
|
||||||
patch_all()
|
#patch_all()
|
||||||
|
|
||||||
|
|
||||||
def create_app():
|
def create_app():
|
||||||
app = Flask(__name__, instance_relative_config=False)
|
app = Flask(__name__, instance_relative_config=False)
|
||||||
|
|
@ -26,9 +25,9 @@ def create_app():
|
||||||
else:
|
else:
|
||||||
print('ENV Variables passed : ', app.config['SQLALCHEMY_BINDS'])
|
print('ENV Variables passed : ', app.config['SQLALCHEMY_BINDS'])
|
||||||
|
|
||||||
# db.init_app(app)
|
db.init_app(app)
|
||||||
with app.app_context():
|
with app.app_context():
|
||||||
from . import routes
|
from . import routes
|
||||||
# db.create_all()
|
db.create_all()
|
||||||
|
|
||||||
return app
|
return app
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue