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

TST: Test against Python 3.12 pre-prelease #14784

Merged
merged 1 commit into from Sep 21, 2023
Merged

Conversation

pllim
Copy link
Member

@pllim pllim commented May 7, 2023

Description

This pull request is to see if we will be compatible with Python 3.12 (#14783). Only the alpha is out, so I am feeling this is going to fail horribly now because we also need upstream stuff to be compatible first. We can always re-run this PR as needed.

Fix #14783

Close #15238 (hopefully)

Companion of #15331

TODO:

Blocked by:

Not blocker but linked to this PR:

@github-actions
Copy link

github-actions bot commented May 7, 2023

Thank you for your contribution to Astropy! 🌌 This checklist is meant to remind the package maintainers who will review this pull request of some common things to look for.

  • Do the proposed changes actually accomplish desired goals?
  • Do the proposed changes follow the Astropy coding guidelines?
  • Are tests added/updated as required? If so, do they follow the Astropy testing guidelines?
  • Are docs added/updated as required? If so, do they follow the Astropy documentation guidelines?
  • Is rebase and/or squash necessary? If so, please provide the author with appropriate instructions. Also see "When to rebase and squash commits".
  • Did the CI pass? If no, are the failures related? If you need to run daily and weekly cron jobs as part of the PR, please apply the "Extra CI" label. Codestyle issues can be fixed by the bot.
  • Is a change log needed? If yes, did the change log check pass? If no, add the "no-changelog-entry-needed" label. If this is a manual backport, use the "skip-changelog-checks" label unless special changelog handling is necessary.
  • Is this a big PR that makes a "What's new?" entry worthwhile and if so, is (1) a "what's new" entry included in this PR and (2) the "whatsnew-needed" label applied?
  • Is a milestone set? Milestone must be set but we cannot check for it on Actions; do not let the green checkmark fool you.
  • At the time of adding the milestone, if the milestone set requires a backport to release branch(es), apply the appropriate "backport-X.Y.x" label(s) before merge.

@github-actions
Copy link

github-actions bot commented May 7, 2023

👋 Thank you for your draft pull request! Do you know that you can use [ci skip] or [skip ci] in your commit messages to skip running continuous integration tests until you are ready?

@pllim
Copy link
Member Author

pllim commented Aug 17, 2023

Huh, why is the devdeps job not picking up numpy 2.0.dev wheel from https://anaconda.org/scientific-python-nightly-wheels/numpy/files ? They seem to have some cp312 ones.

@pllim
Copy link
Member Author

pllim commented Aug 17, 2023

Looks like asdf-astropy is downgrading numpy for some reason...

https://github.com/astropy/astropy/actions/runs/5896110330/job/15993310599?pr=14784

@WilliamJamieson
Copy link
Contributor

Looks like asdf-astropy is downgrading numpy for some reason...

astropy/astropy/actions/runs/5896110330/job/15993310599?pr=14784

It is not, for some reason it had oldest-supported-numpy as a build-system dependency which was never necessary.

astropy/asdf-astropy#193 should fix this.

@pllim

This comment was marked as resolved.

@pllim pllim force-pushed the python-3.12 branch 2 times, most recently from 2c0a48d to 8a612a4 Compare August 18, 2023 21:43
@pllim
Copy link
Member Author

pllim commented Aug 18, 2023

pyerfa is still not playing well with Python 3.12 (see errors in liberfa/pyerfa#111). I have to disable it here.

@pllim pllim added Build all wheels Run all the wheel builds rather than just a selection and removed Experimental labels Aug 18, 2023
@pllim

This comment was marked as resolved.

@pllim pllim mentioned this pull request Aug 18, 2023
1 task
@pllim
Copy link
Member Author

pllim commented Aug 19, 2023

Ah... maybe because numpy 1.25 does not have a cp312 wheel, so it is trying to build numpy from source before building astropy...

.github/workflows/publish.yml Outdated Show resolved Hide resolved
@mwcraig

This comment was marked as resolved.

@pllim

This comment was marked as resolved.

@mhvk
Copy link
Contributor

mhvk commented Sep 21, 2023

@pllim - the deprecation of np.char seems quite painful -- it appears we use it in quite a few places. I had a quick look and think the use in astropy.table is fairly easy to fix, but I'm more worried about io.fits... It may be an idea to just filter the warning for now here, so you can make wrap this up (of course, raising a separate issue...).

@pllim
Copy link
Member Author

pllim commented Sep 21, 2023

Actually the chararray stuff might not be as dire as it sounds. I only found one line that needed replacing I think. Let's see what the CI says over at #15363 🤞

Also have to catch KeyError in NDSlicingMixin for uncertainty and mask now.

BLD: Add py312 wheels.

BLD: Update cython to 0.29.36 for Python 3.12.
@pllim pllim marked this pull request as ready for review September 21, 2023 16:10
@pllim pllim merged commit ea32c9c into astropy:main Sep 21, 2023
56 checks passed
@lumberbot-app

This comment was marked as resolved.

@pllim
Copy link
Member Author

pllim commented Sep 21, 2023

Of course there are conflicts. Otherwise it would be too easy. I'll take care of it.

@mhvk
Copy link
Contributor

mhvk commented Sep 21, 2023

Thanks so much, @pllim!!! 🎆

pllim added a commit that referenced this pull request Sep 21, 2023
for Pyhon 3.12. This was supposed to be in #14784 but got lost in rebase.

Co-authored-by: Maximilian Linhoff <maximilian.linhoff@tu-dortmund.de>
@pllim
Copy link
Member Author

pllim commented Sep 21, 2023

maxnoe's Cython bump was lost in the rebase. I fixed at in 709ce95 in main. 😬

pllim added a commit to pllim/astropy that referenced this pull request Sep 21, 2023
pllim added a commit to pllim/astropy that referenced this pull request Sep 22, 2023
pllim added a commit to pllim/astropy that referenced this pull request Sep 22, 2023
pllim added a commit that referenced this pull request Sep 22, 2023
…e-prelease) (#15370)

* Backport PR #14784: TST: Test against Python 3.12 pre-prelease

* cosmology changed a lot

* DOC: main has no more setup.cfg but that is irrelevant for v5.3.x so we just stop cross-ref.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Build all wheels Run all the wheel builds rather than just a selection Python 3.12 testing 💤 backport-v5.3.x on-merge: backport to v5.3.x
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test failures with Python 3.12 and astropy 5.3.2 TST: Python 3.12 support
10 participants