Repository navigation
Update testing and CI: tox-uv, lowest-resolution oldestdeps, role-based job names - #324
Merged
Merged
Conversation
- Use tox-uv; oldestdeps now uses uv's "lowest" resolution with oldestdeps-constraints.txt for transitive dependencies instead of hand-maintained pins. Replace pip-specific settings with uv equivalents. - Reorganize CI: default Python 3.14, role-based job names, new oldest-dependencies job, macOS/Windows on 3.14, devdeps as a separate allowed-failure job on Python 3.15 with remote data. - Raise minimums found broken by the lowest resolution: numpy>=1.26.0, gwcs>=0.24.0; add minimums for synphot, pytest, pytest-astropy and photutils in the test extra. Drop tox from the test extra. - Use a compound model in test_from_asdf_raises_on_unsupported_transform, since asdf < 4 can't serialize a single model with a 1D bounding box. - Force the Agg matplotlib backend in the root conftest.py. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #324 +/- ##
=======================================
Coverage 92.54% 92.54%
=======================================
Files 18 18
Lines 2348 2348
=======================================
Hits 2173 2173
Misses 175 175 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
tox was dropped from the test extra because that extra is installed inside each tox environment, where tox isn't needed. The new dev extra installs the test, docs and all extras together with tox and tox-uv for local development. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
pllim
approved these changes
Oct 22, 2026
pllim
left a comment
Member
There was a problem hiding this comment.
I need to update GHA versions for security. But this gets in the way. So I am just gonna merge. You all can debate more in follow-up PRs if needed. Thanks for your understanding.
Member
|
Not a fan of the claude file but you do you. |
Member
|
p.s. I also updated the change log while I was resolving conflict. Test/infrastructure changes do not need change log. If you disagree, feel free to edit the entry in separate PR. |
Contributor
Author
|
all sounds good! thank you much, @pllim! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This updates the testing infrastructure to match astropy/astroplan#641, adapted to specreduce.
Testing infrastructure
tox-uv, which tox installs automatically throughrequires. pip-specific settings are replaced with their uv equivalents:{list_dependencies_command}instead ofpip freeze, andUV_EXTRA_INDEX_URLwithunsafe-best-matchsodevdepscan mix nightly and PyPI packages. The git-installed devdeps (specutils, synphot) usepkg @ git+...syntax.oldestdepsuses uv'slowestresolution. Every package is installed at the lowest version allowed, instead of relying on hand-written pins.pyproject.toml.oldestdeps-constraints.txt, applied throughUV_CONSTRAINT. Each is the first release after Python 3.12.0 came out (the rule is in the file's header), worked out across platforms withuv pip compile --universal.default_python:conftest.pyforces theAggmatplotlib backend.Minimum versions
Testing the real minimums showed several didn't work:
numpy>=1.24→>=1.26.0: 1.24 and 1.25 have no Python 3.12 builds.gwcs(unbounded) →>=0.24.0: with specutils 2.0 and gwcs 0.22, creating aSpectrumwithout a spectral axis fails withUnitConversionError: 'pix' and '' (dimensionless) are not convertible.synphot→>=1.3.post0, the first release with Python 3.12 wheels.testextra:pytest>=7.4.0,pytest-astropy>=0.11.0, andphotutils>=1.11to matchall.toxis dropped from thetestextra: that extra is installed inside each tox environment, where tox isn't needed, and the lowest resolution would install an ancient tox there. A newdevextra (pip install -e ".[dev]") installs thetest,docsandallextras together withtoxandtox-uvfor local development.asdf-astropy>=0.8.0is in the constraints file: older versions serialize units through VOUnit and warn that Angstrom is deprecated, whichfilterwarnings = errormakes fatal.Test change
test_from_asdf_raises_on_unsupported_transformnow usesScale | Polynomial1Drather than a barePolynomial1D. With asdf < 4, a GWCS whose transform is a single model with a 1-D bounding box fails schema validation when written.to_asdfalways writes a compound shift→polynomial, so users aren't affected.Not included
SynthImage.add_poisson_noise(). It can be added once photutils supports free threading.Testing
Run locally with tox:
py312-test-oldestdeps(numpy 1.26.0, astropy 6.0.0, scipy 1.14.1, matplotlib 3.10.0, specutils 2.0.0, gwcs 0.24.0, asdf 3.3.0, pytest 7.4.0)py312-test,py313-test,py314-test,codestylepy314-test-alldeps-cov, remote datapy314-test-alldeps-predepspy315-test-devdeps(Python 3.15.0rc2; astropy 8.1.dev, numpy 2.6.dev, scipy 2.0.dev)linkcheckwas not run locally.🤖 Generated with Claude Code