Skip to content

Bump minimum Python to 3.10 - #15603

Merged
pllim merged 6 commits into
astropy:mainfrom
nstarman:bump-py-310
Mar 8, 2024
Merged

pllim merged 6 commits into
astropy:mainfrom
nstarman:bump-py-310

Conversation

@nstarman

@nstarman nstarman commented Nov 11, 2023 •

Copy link
Copy Markdown
Member

v6.1 will be py3.10+.

  • By checking this box, the PR author has requested that maintainers do NOT use the "Squash and Merge" button. Maintainers should respect this when possible; however, the final decision is at the discretion of the maintainer that merges the PR.

@nstarman nstarman added this to the v6.1 milestone Nov 11, 2023
@nstarman nstarman added whatsnew-needed Extra CI Run cron CI as part of PR labels Nov 11, 2023
@nstarman
nstarman force-pushed the bump-py-310 branch 3 times, most recently from 3759be6 to bb72973 Compare November 11, 2023 16:46
Comment thread .github/workflows/ci_cron_weekly.yml Resolved
@nstarman

nstarman commented Nov 11, 2023 •

Copy link
Copy Markdown
Member Author

I bumped SciPy to 1.6, but looking at PyPI, SciPy v1.7.2 is the minimum version officially supporting py3.10 (https://pypi.org/project/scipy/1.7.2/). I guess we need to bump to SciPy v1.7.2?

Edit: numpy 1.23+ means we actually need SciPy 1.8+

Comment thread .circleci/config.yml Resolved
@nstarman
nstarman force-pushed the bump-py-310 branch 2 times, most recently from b25e30c to eb2ae71 Compare November 11, 2023 23:07
@dhomeier dhomeier changed the title Bump Python to 3.10 Bump minimum Python to 3.10 Nov 13, 2023
Comment thread .ruff.toml Resolved
Comment thread CONTRIBUTING.md Resolved
Comment thread CONTRIBUTING.md Resolved
Comment thread astropy/cosmology/funcs/comparison.py Resolved
@nstarman
nstarman force-pushed the bump-py-310 branch 2 times, most recently from e475d9e to 3327c31 Compare November 25, 2023 19:50
@nstarman

nstarman commented Nov 25, 2023 •

Copy link
Copy Markdown
Member Author
  • Documentation link check is failing because Astropy v6.0 isn't out yet but the docs have a link referencing v6.0
  • Tests "Python 3.12 with dev version of key dependencies" are numpy issues and I think unrelated to this PR.
  • Image test failures are real because the images need to be regenerated.

@pllim, I don't think I have the permissions to address the last point.

@eerovaher

Copy link
Copy Markdown
Member

If it is possible to update the minimum required numpy and scipy versions without having to update the reference images then it would be a good idea to open a separate pull request for that.

@nstarman nstarman mentioned this pull request Dec 10, 2023
1 task done
@nstarman
nstarman force-pushed the bump-py-310 branch 3 times, most recently from 38334be to 186d842 Compare December 15, 2023 16:16
@nstarman nstarman mentioned this pull request Dec 15, 2023
1 task done
@saimn

saimn commented Dec 18, 2023

Copy link
Copy Markdown
Contributor

3.10 is supposed to be supported until April, so if we want to have the option to release a minor version before that (e.g. for Numpy 2.0 in February) this PR should wait.

nstarman and others added 5 commits February 27, 2024 14:05
Signed-off-by: nstarman <[email protected]>
With manual fixes for ruff-identified non-autofixable issues.

Co-authored-by: Clément Robert <[email protected]>
Signed-off-by: nstarman <[email protected]>
Comment thread .github/workflows/ci_cron_weekly.yml Resolved

@pllim pllim left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I like the clean-up but I won't merge yet to give other maintainers a chance to review. Though if you don't hear back from anyone else, we should get this in sooner than later to give downstream a chance to test this via nightly wheel.

Please ping me next week if no one else approves.

Thanks!

@pllim

pllim commented Feb 27, 2024

Copy link
Copy Markdown
Member

p.s. Auto merge won't work because the branch protection rules need updating but I cannot do that until after merge. I can override the protection when we have enough approvals.

@mhvk mhvk left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Great, thanks! Good as is, but if you address the second comment, might as well do the first too.

distribution::

conda create --name apy-1761 python=3.9 # replace 3.9 with desired version
conda create --name apy-1761 python=3.10 # replace 3.10 with desired version

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If there are any other changes requested, might as well change this to 3.12 so we don't have to repeat it for a while...

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

✅

Comment thread docs/units/type_hints.rst Outdated

.. doctest-skip::

>>> T.Union[Quantity[u.m], None]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do you want to change this one to Quantity[u.m] | None too?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

✅

@eerovaher eerovaher left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I have just one small remark.

Signed-off-by: nstarman <[email protected]>

@eerovaher eerovaher left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The patch here looks good to me. The commit history is a bit messy, but that could be fixed by squashing.

@nstarman

nstarman commented Mar 8, 2024

Copy link
Copy Markdown
Member Author

Please ping me next week if no one else approves.

@pllim.

@pllim

pllim commented Mar 8, 2024

Copy link
Copy Markdown
Member

Yup yup... 😬

@pllim
pllim merged commit 06f9f34 into astropy:main Mar 8, 2024
@pllim

This comment was marked as resolved.

@pllim

pllim commented Mar 8, 2024

Copy link
Copy Markdown
Member

Branch protection rules updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Extra CI Run cron CI as part of PR whatsnew-needed zzz 💤 Python3.10 archived: Python 3.10 is no longer supported

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

7 participants