Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to Flask 3 #1801

Open
jotaen4tinypilot opened this issue May 21, 2024 · 2 comments
Open

Upgrade to Flask 3 #1801

jotaen4tinypilot opened this issue May 21, 2024 · 2 comments

Comments

@jotaen4tinypilot
Copy link
Contributor

jotaen4tinypilot commented May 21, 2024

Flask 3 was released in September 2023. We are still on Flask 2 right now.

Flask is our web server library, so it’s probably one of our most important dependencies. Also, a lot of the indirect Python dependencies are brought in via Flask, e.g. Jinja or Werkzeug. So by upgrading Flask, we can potentially upgrade a lot of our other dependencies as well.

I already naively tried the upgrade, but there seem to be breaking API changes in the library which affect our code, which we have to look into more closely. The server process crashed upon startup, because due to methods having been renamed/removed in the flask_wtf package that we apparently depend on. I didn’t investigate further.

@mohamedtaee
Copy link

mohamedtaee commented May 26, 2024

@jotaen4tinypilot curious, what are some specific endpoints that broke with Flask 3?

Tagging @jotaen just in case the tagged account above is less active.

@jotaen4tinypilot
Copy link
Contributor Author

jotaen4tinypilot commented Jun 3, 2024

I’ve updated the ticket description: the server process crashed upon startup, because apparently there had been breaking changes in the flask_wtf package, where methods have been renamed/removed. So it’s not a problem with any of our HTTP endpoints, but with the method API of the flask_wtf package. I didn’t investigate further, so it might potentially be that this is the only problem.

The problem was immediately obvious after bumping Flask to version 3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants