Skip to content

Commit 4517270

Browse files
authored
fix(deps): update to Flask 3.0.0, update deprecated decorator (GoogleCloudPlatform#10727)
1 parent 9a020ee commit 4517270

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

run/idp-sql/main.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,8 @@
2626
app = Flask(__name__, static_folder="static", static_url_path="")
2727

2828

29-
@app.before_first_request
30-
def create_table() -> None:
31-
"""Initialize database connection and table on startup."""
29+
"""Initialize database connection and table on startup."""
30+
with app.app_context():
3231
database.create_tables()
3332

3433

run/idp-sql/requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Flask==2.1.0
1+
Flask==3.0.0
22
SQLAlchemy==2.0.17
33
pg8000==1.29.8
44
gunicorn==20.1.0

0 commit comments

Comments
 (0)