python启动方式变化

This commit is contained in:
qiaoxinjiu
2026-04-15 11:08:14 +08:00
parent 52bd14b396
commit 77f94f9aa3
2 changed files with 6 additions and 1 deletions

View File

@@ -5,7 +5,10 @@ from app import create_app
app = create_app()
CORS(app, resources=r'/*')
app.run(host="0.0.0.0", port=int("5010"), debug="debug")
if __name__ == '__main__':
app.run(host='0.0.0.0', port=5010, debug=True)
def cors_response(res):