Skip to content

BLD: Drop Python 3.10 support #60059

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

Open
2 tasks done
wirable23 opened this issue Oct 16, 2024 · 16 comments
Open
2 tasks done

BLD: Drop Python 3.10 support #60059

wirable23 opened this issue Oct 16, 2024 · 16 comments
Labels
Build Library building on various platforms Dependencies Required and optional dependencies Python 3.10
Milestone

Comments

@wirable23
Copy link

Research

  • I have searched the [pandas] tag on StackOverflow for similar questions.

  • I have asked my usage related question on StackOverflow.

Link to question on StackOverflow

NA

Question about pandas

Per spec0, python 3.10 support should be dropped. Will pandas 3 still support it?

@wirable23 wirable23 added Needs Triage Issue that has not been reviewed by a pandas team member Usage Question labels Oct 16, 2024
@rhshadrach
Copy link
Member

I believe we follow NumPy who has adopted Spec0, which means we should drop support with pandas 3.0 (or even 2.3?).

cc @jorisvandenbossche @WillAyd @mroeschke

@rhshadrach rhshadrach added the Dependencies Required and optional dependencies label Oct 26, 2024
@WillAyd
Copy link
Member

WillAyd commented Oct 27, 2024

I think 2.3 will continue to support 3.10 but yea probably worth dropping by the time 3.0 gets out

@jorisvandenbossche
Copy link
Member

I would also certainly keep support for 2.3 (there is not that much reason to drop it now and backport those changes IMO)

@rhshadrach rhshadrach added Build Library building on various platforms and removed Usage Question Needs Triage Issue that has not been reviewed by a pandas team member labels Oct 28, 2024
@rhshadrach rhshadrach changed the title QST: Will pandas 3 support python 3.10? BLD: Drop Python 3.10 support Oct 28, 2024
@simonjayhawkins simonjayhawkins added this to the 3.0 milestone Nov 14, 2024
@simonjayhawkins
Copy link
Member

The motivation for SPEC 0 - Minimum Supported Dependencies is that limiting the scope of supported dependencies helps reduce the maintenance burden, allowing developers to focus on adding features, fixing bugs, and optimizing performance.

SPEC 0 states that support for Python versions should be dropped 3 years after their initial release. Python 3.10 was released in October 2021 and so, according to the spec we now follow, should be dropped for the forthcoming 2.3 release.

We don't drop support for Python in patch releases and so if not dropped for 2.3, we would need to ensure support for all subsequent 2.3.x releases. If we follow previous release schedules this could be around 6 months.

I would also certainly keep support for 2.3 (there is not that much reason to drop it now and backport those changes IMO)

there is also not that much reason not to drop it?

@jorisvandenbossche
Copy link
Member

there is also not that much reason not to drop it?

For a maintenance branch like 2.3, it's more work to drop it than to not drop it ..

Also, SPEC0 does not require you to drop a version immediately when allowed according to their schedule, only that it is fine to drop it from that point

@WillAyd
Copy link
Member

WillAyd commented Nov 14, 2024

I would add that maintaining 2.3 has already been rather challenging. The bar to put any changes into that which are not related to the string data type should be really high, and I don't think dropping 3.10 would be worth it

@simonjayhawkins
Copy link
Member

I must be underestimating the amount of work to drop support. I wasn't expecting the codebase on 2.3.x to be updated to take advantage of python 3.11 features just changing requires-python in pyproject.toml, removing some ci jobs and updating the release notes?

@WillAyd
Copy link
Member

WillAyd commented Nov 14, 2024

It's more risk of allowing 3.11+ features into main and then having to come up with an alternative during backport

@jorisvandenbossche
Copy link
Member

@WillAyd that risk is more related to dropping 3.10 already now in main, not so much for dropping 3.10 in 2.3.x branch (and not only for having to come up with an alternative, but also just to have more conflicts. So for me that is a reason to wait a bit longer with dropping Python 3.10 for main, although we can certainly do that for 3.0).

Anyway, it's indeed not much work to drop it on 2.3.x (we probably already spent more time discussing this than it takes to actually do it ..), but it is still work with basically zero benefit to us (it's not that we are planning to use features on the 2.3.x branch, so then why drop it?), just for the reason to blindly follow a strict interpretation of SPEC0.
I would propose to spent our time on more useful things for the 2.3.x branch, and if at some point there is actually an issue with Python 3.10 on that branch, we can still drop it then.

@simonjayhawkins
Copy link
Member

and if at some point there is actually an issue with Python 3.10 on that branch, we can still drop it then.

In our version policy we updated the Python support section to say pandas mirrors the NumPy guidelines for Python support. which itself states
Minimum Python and NumPy version support should be adjusted upward on every major and minor release, but never on a patch release. This is our current published policy as IIUC the adoption of SPEC 0 - Minimum Supported Dependencies has not yet been communicated to users.

So I don't think we could drop support for Python 3.10 in a patch release.

AFAICT there is not this restriction in SPEC 0.

It's more risk of allowing 3.11+ features into main and then having to come up with an alternative during backport

this will happen soon anyway when we drop 3.10 on main. I don't get that we would need a alternative. We would need an alternative if we don't drop 3.10 on 2.3.x?

@WillAyd
Copy link
Member

WillAyd commented Nov 14, 2024

What is the urgency to dropping 3.10 on main? I was under the impression we would just do it closer to the 3.x release, towards the end of the 2.3 lifecycle

@simonjayhawkins
Copy link
Member

It was mentioned that we shouldn't blindly follow the spec but that spec has been created with recommendations that all projects across the Scientific Python ecosystem adopt it.

IIUC pandas 3.0.0rc could be released very shortly after 2.3.0. If this happens then I assume we will not be following our normal release lifecycle and will be actively maintaining 2 released versions simultaneously.

@simonjayhawkins
Copy link
Member

of course, as users assume we are still following NEP29 until we communicate the changes (currently in the 3.0.0 release notes), we could drop Python 3.10 in 3.1 instead of 3.0 and this avoids the potential overlap with the 2.3.x branch.

@jack-mcivor
Copy link
Contributor

jack-mcivor commented May 27, 2025

FWIW numpy==2.3.0rc1 is out now and drops support for 3.10 numpy/numpy#27861 https://github.com/numpy/numpy/releases/tag/v2.3.0rc1

@simonjayhawkins
Copy link
Member

in #60059 (comment) I wrote

We don't drop support for Python in patch releases and so if not dropped for 2.3, we would need to ensure support for all subsequent 2.3.x releases. If we follow previous release schedules this could be around 6 months.

6 months on from this comment and with 2.3 not yet released we should ensure that dropping Python 3.10 support is now done before the 2.3 release which is scheduled for the end of this month? #59664 (comment)

@mroeschke
Copy link
Member

I think it's OK for 2.3 to keep support for Python 3.10. For pandas 3.0, I would support dropping Python 3.10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Library building on various platforms Dependencies Required and optional dependencies Python 3.10
Projects
None yet
Development

No branches or pull requests

7 participants