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

Require Flask >= 2.2.0 #224

Merged
merged 1 commit into from
Dec 11, 2023
Merged

Require Flask >= 2.2.0 #224

merged 1 commit into from
Dec 11, 2023

Conversation

jeffwidman
Copy link
Member

@jeffwidman jeffwidman commented Dec 7, 2023

Require Flask >= 2.2.0.

I'm comfortable going up to requiring 3.x, but when I grep'd for
places we use older Flask constructs, this was all I found.

So for now no need to jump further.

Flask 2.2.0 requires Python >= 3.7, so also dropped older pythons.

I also dropped the Python 3.6 test from being required on the repo branch settings.

Fix #222

@jeffwidman jeffwidman changed the title Require Flask >= 3.0 Require Flask >= 2.2.0 Dec 7, 2023
@nickjj
Copy link
Contributor

nickjj commented Dec 7, 2023

If we're going to drop support for older versions of Flask I do prefer allowing 2.2+ vs 3.0+.

Based on doing a lot of contract work, it may be surprising at how many folks are using older versions of Flask. One of the biggest Flask apps I've worked with (client) is still running 1.1. It has around ~500k lines of Flask / Python code. They use this extension but I think they would be fine sticking with the latest 0.14 release.

One of the orgs I worked with recently was running 2.0 for a long time and recently upgraded to 3.0.

For context:

  • Flask 2.0.0 was released on 2021-05-11
  • Flask 2.1.0 was released on 2022-03-28
  • Flask 2.2.0 was released on 2022-08-01
  • Flask 2.3.0 was released on 2023-04-25
  • Flask 3.0.0 was released on 2023-09-30

@jeffwidman
Copy link
Member Author

It doesn't surprise me. I've worked in the real world too. 😁

Agree it's a reasonable request, so I switched from 3.0 to 2.2.0 as the minimum.

As a consequence, 2.2.0 requires Python 3.7, so we also drop support for Python 2.7/3.6. IMO that's fine as both have been EOL'd for a while, so anyone still on that old version of Python is unlikely to be updating a small random Flask extension.

@jeffwidman
Copy link
Member Author

Let's hold off on merging this for a few weeks just to ensure our release of the 0.14.x series is stable and we don't encounter more blocker bugs like:

Also IMO merging this will result in at least a 0.15.0 version bump, possibly higher depending on if we go semver or not.

@nickjj
Copy link
Contributor

nickjj commented Dec 7, 2023

Just to give us some confidence, I pulled 0.14.1 into a real Flask 3.0 project and it's all good. There are deprecation warnings to address which should still work with Flask 2.2.0.

@jeffwidman
Copy link
Member Author

Nice, thanks for checking that!

From what I can tell, this PR actually removes all usage of flask.__version__, so merging this will also resolve that deprecation warning.

Require Flask >= `2.2.0`.

I'm comfortable going up to requiring `3.x`, but when I grep'd for
places we use older Flask constructs, this was all I found.

So for now no need to jump further.

Flask `2.2.0` requires Python >= `3.7`, so also dropped older pythons.
Copy link
Contributor

@macnewbold macnewbold left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, and cleans up nicely some things that we won't need.

@macnewbold macnewbold merged commit b03a2e6 into master Dec 11, 2023
10 checks passed
@macnewbold macnewbold deleted the require-flask-3 branch December 11, 2023 18:27
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Drop support for Flask < 2.2.0 (and implicitly Python < 3.7)
3 participants