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

maintenance: add python 3.12 compatibility, uv, dependencies #259

Merged
merged 33 commits into from
Sep 18, 2024
Merged

Conversation

mikapfl
Copy link
Member

@mikapfl mikapfl commented Sep 12, 2024

Pull request

Please confirm that this pull request has done the following:

  • Tests added
  • Documentation added (where applicable)
  • Description in a .rst file in the directory changelog_unreleased added - remember to include a * to make it a bullet point

Description

  • Add python 3.12 compatibility - closes: Unit handling in xarray fails for Python 3.12 #205 closes: Python 3.12 compatibility #255
    This only needed updates in our dependencies, so easy to do.
  • Tighten dependencies - we now have minimum supported versions for all dependencies.
  • Add testing with the lowest supported versions to github action workflows
  • Use uv pip instead of pip everywhere, it is faster
  • optimize github actions for more caching

@mikapfl
Copy link
Member Author

mikapfl commented Sep 12, 2024

This was surprisingly easy to do, until I started testing on Windows, then it was surprisingly hard to do.

Copy link

codecov bot commented Sep 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.00%. Comparing base (1f0ccc3) to head (782d258).
Report is 16 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #259      +/-   ##
==========================================
+ Coverage   96.97%   97.00%   +0.02%     
==========================================
  Files          45       45              
  Lines        4336     4336              
==========================================
+ Hits         4205     4206       +1     
+ Misses        131      130       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mikapfl
Copy link
Member Author

mikapfl commented Sep 12, 2024

We now do caching via uv and it works quite well. This is also more important now that we have a larger test matrix, which also involves somewhat unusual combinations of older library versions on newer python versions. These need to be compiled often because binary wheel are not available, which takes quite long, but is nicely cached by uv.

@mikapfl
Copy link
Member Author

mikapfl commented Sep 12, 2024

I also re-enabled xdoctests, they were relatively easy to fix and are useful after all.

@mikapfl mikapfl self-assigned this Sep 12, 2024
@mikapfl mikapfl requested review from JGuetschow and crdanielbusch and removed request for JGuetschow September 12, 2024 15:00
@mikapfl mikapfl merged commit 98699fb into main Sep 18, 2024
16 checks passed
@mikapfl mikapfl deleted the maintenance branch September 18, 2024 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Python 3.12 compatibility Unit handling in xarray fails for Python 3.12
2 participants