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

Add support for Python 3.12 #4146

Merged
merged 8 commits into from
Jan 5, 2024
Merged

Add support for Python 3.12 #4146

merged 8 commits into from
Jan 5, 2024

Conversation

abey79
Copy link
Member

@abey79 abey79 commented Nov 6, 2023

What

I added a bunch of fixes to scripts/run_all.py, which has a marked tendency to bit rot:

Some workaround introduced to deal with PyTorch not 3.12 ready, see:

TODO:

  •  nox -s tests-3.12 passing
  • nox -s run_all-3.12 --save passing
  • nox -s roundtrips-3.12 passing
  • Solve this:
    ❯ pixi add pyarrow==14.0.0 
    × could not determine any available versions for pyarrow on linux-64. Either the package could not be found or version constraints on other dependencies result in a conflict.
    ╰─▶ Cannot solve the request because of: No candidates were found for pyarrow ==14.0.0.
    
  • Test won't pass until torch is updated for 3.12: Pytorch for Python 3.12 not available pytorch/pytorch#110436

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested demo.rerun.io (if applicable)
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG

@abey79 abey79 added blocked can't make progress right now include in changelog 🐍 Python API Python logging API do-not-merge Do not merge this PR and removed blocked can't make progress right now labels Nov 6, 2023
@genemerewether
Copy link

Hi, any plans to merge this or are you waiting for the pytorch test dep? thanks!

@abey79
Copy link
Member Author

abey79 commented Jan 5, 2024

PyTorch is still not released for python 3.12 sadly, but apparently the nightly works. Maybe we could have test work by updating our requirements_*.txt with:

torch ; python_version < "3.12"
--pre --index-url https://download.pytorch.org/whl/nightly torch ; python_version >= "3.12"

EDIT: ☝🏻 that doesn't work (--pre and --index-url apply to the entire requirement.txt file). I found another way to get tests to pass.

@genemerewether
Copy link

PyTorch is still not released for python 3.12 sadly, but apparently the nightly works. Maybe we could have test work by updating our requirements_*.txt with:

torch ; python_version < "3.12"
--pre --index-url https://download.pytorch.org/whl/nightly torch ; python_version >= "3.12"

That would be great, if you're open to it. My env requires pyarrow >= 14 and I've been eagerly waiting to integrate rerun (having tested in a separate env)

@abey79
Copy link
Member Author

abey79 commented Jan 5, 2024

I could get nox -s tests-3.12 to pass by gating torch in requirements_*.txt and explicitly installing its nightly in noxfile.py.

@abey79 abey79 removed the do-not-merge Do not merge this PR label Jan 5, 2024
@abey79 abey79 marked this pull request as ready for review January 5, 2024 16:23
@jleibs jleibs merged commit 67d6dd8 into main Jan 5, 2024
40 checks passed
@jleibs jleibs deleted the antoine/python-3.12 branch January 5, 2024 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support Python 3.12
3 participants