Repository navigation
ci(python): declare the version tiers and the latest version in one file (#1660) - #1677
Conversation
|
Verdict: GOOD TO GO at What changed. What the reviewer checked. It ran its own expander over all seven matrix jobs: the legs, names, Exempt, each with its reason: lint stays on 3.14, because pylint/astroid crashes on Unverified until CI runs: GitHub's Conflicts expected with #1672, which is in progress and touches the same workflows. Part B, the monitor, follows as its own PR. |
|
Coverage: 89.46% (unit tier, Python 3.14,
Per-file detail: the |
|
Can we use JSON with comments format for the definition file? Or maybe let's use YAML if it’s a better choice. If we don't wanna introduce new dependencies, config format ( Also, I'd prefer we keep all single-instance workflows on the latest Python versions, like linting, release, CI timing etc., unless it's incompatible like the PyPCAP parity tests. |
|
Recorded, two items. Format: TOML, unless you'd rather another. It carries comments, Python reads it with the standard library (
Single-interpreter jobs on the latest Python. Release, CI timing, docs, coverage, the crons and the gate already move to 3.15 in this PR, and pypcap-parity keeps 3.11, as you said. Lint is the one held back, because it is measured incompatible: on 3.15, pylint 4.1.3 / astroid 4.3.4 crashes on
|
a52c2b4 to
c605ea3
Compare
…1660) - Review on #1677 asked for a tier file that holds comments. .github/python-versions.json becomes .github/python-versions.toml with the same data, one inline table per version, so a tier move is still a one-line diff. The "//" note and each exemption's reason are comments; an exemption has no `reason` key. - util/python_versions.py and util/ci_timing.py read it with tomllib (3.11+). Every job that runs the script on the runner's own python3 is on ubuntu-latest or macos-latest, whose python3 is 3.12 or newer. No dependency is added. - Tests that read the file skip without tomllib, as on the KTLO legs (3.8-3.10). New tests: the file is TOML and each exemption has a comment, each runner's python3 has tomllib, the skips hold without it, and the workflows page cites each version's line. - Sparse checkouts, comments, docs and line citations follow the rename. New tests fail on the parent and pass here; old and new script outputs are identical; actionlint findings unchanged.
|
Verdict: GOOD TO GO at Round 2.
Still open: lint's version, the question above; this PR keeps lint on 3.14 until you choose. One date is inconsistent: the runner's own notice says |
|
what's wrong with asteroids? and yea, everything else lint on 3.15 then |
|
Recorded: everything except pylint runs lint on 3.15. Before settling for that, a worker is trying newer pylint/astroid releases so that pylint can move too. What's wrong with astroid. The crash (F0002 If a version works, lint moves to 3.15 entirely. Otherwise this PR ships option 1, with only pylint held on 3.14 and the reason recorded in the tier file. |
|
GOOD TO GO carries to |
…ile (#1660) - Python versions were spelt out in every matrix, so a tier change meant a sweep of many files. .github/python-versions.json now gives each CPython and PyPy version one line with its tier and, where ubuntu-latest cannot provide it, its runner; it names `latest` and lists the pins kept off it. - util/python_versions.py reads it with the runner's own python3. Every matrix (test, integration, engine-tests, pypcap-parity, compatibility, pypi, conda, conda-dist) and every single-interpreter job's version comes from its outputs; the release completeness checks count its tags. Job and required-check names are unchanged. - The single-interpreter jobs move to `latest`, 3.15 (#1661): the gate, now `Gate (full suite, Python 3.15)`, the coverage and sdist legs, ordering, docs, crons, CI Timing. lint.yml stays on 3.14, an exemption in the file. - New tests/project/test_python_versions_1660.py: the file reproduces main's matrices bar the coverage leg, no workflow pins a version the file does not list, and the classifiers, docs and comments agree with it. The tier tests, #1672's KTLO tests included, read the file; the workflows page says a tier change is a one-line edit plus the ruleset. New tests fail on origin/main and pass here; actionlint findings unchanged.
…1660) - Review on #1677 asked for a tier file that holds comments. .github/python-versions.json becomes .github/python-versions.toml with the same data, one inline table per version, so a tier move is still a one-line diff. The "//" note and each exemption's reason are comments; an exemption has no `reason` key. - util/python_versions.py and util/ci_timing.py read it with tomllib (3.11+). Every job that runs the script on the runner's own python3 is on ubuntu-latest or macos-latest, whose python3 is 3.12 or newer. No dependency is added. - Tests that read the file skip without tomllib, as on the KTLO legs (3.8-3.10). New tests: the file is TOML and each exemption has a comment, each runner's python3 has tomllib, the skips hold without it, and the workflows page cites each version's line. - Sparse checkouts, comments, docs and line citations follow the rename. New tests fail on the parent and pass here; old and new script outputs are identical; actionlint findings unchanged.
- lint.yml reads `latest` from .github/python-versions.toml like every other single-interpreter job; the file drops its lint exemption. - On setup-python's 3.14.8 and 3.15.0 builds, pylint 4.1.3 (astroid 4.3.4) reports the same messages, and bandit, mypy and vermin the same reports. The 3.15 crash recorded earlier came from faking a missing `_decimal` with `sys.modules['_decimal'] = None`, which crashes 3.14.8 identically. - Tests: lint joins the single-interpreter jobs that must run `latest`, and its pin at 1024109 joins the scan's known pins. - CONTRIBUTING and the workflows page no longer name lint's 3.14. tests/project: 265 passed, 1 skipped; actionlint 1.7.12: 28 findings, as on main.
|
The red On the coverage leg, which this PR moves to 3.15, The fix is to block the import rather than assert it is absent: |
|
Correction: pylint works on 3.15, and the crash I reported was our own artifact. To mimic setup-python's 3.15, which has no C Round 3 measured setup-python's real 3.15.0 tarball, sha256-checked, in an That push also carries the fix for the |
…ded (#1660) - The coverage leg failed test_without_tomllib_the_tests_that_read_the_file_skip: `patch = subprocess` in .github/coverage.toml starts coverage in every child, and coverage reads its TOML config, so the probe interpreter already held tomllib and its `assert 'tomllib' not in sys.modules` raised. - The probe now drops tomllib and its submodules from sys.modules and sets the entry to None, so any import raises ModuleNotFoundError, an ImportError, loaded or not. The meta-path finder and the assert go; the two scripts' expected error is the new message. Fails before and passes after under `coverage run --rcfile=.github/coverage.toml` on 3.14.8 and 3.15.0; the file passes in full (24 passed, 142 subtests), plain and under coverage; the test passes on 3.8 and 3.10.
627fa25 to
775d6c7
Compare
|
Verdict: GOOD TO GO at
|
Please follow the guide below
You will be asked some questions, please read them carefully and answer honestly
Put an
xinto all the boxes [ ] relevant to your pull request (like that [x])Use Preview tab to see how your pull request will actually look like
Searched for similar pull requests
Followed the coding style (
make pylint,make mypy,make isort)make testpasses, and a test case covers the change -- tests cover it; only the touchedtests/projectmodules were run locally, the full suite is CI'sAdded a changelog entry under
docs/source/changelog/and regeneratedCHANGELOG.md, if the change is user-visible -- N/A — centralised in docs(changelog): shared 1.5.0 changelog — long-lived, merges last (#610, #616, #617, #618, #620) #657What is the purpose of your pull request?
Tick the commit type your subject line carries.
fix— corrects a defectfeat— adds a featureperf— changes performance, not behaviourrefactor— changes neither behaviour nor performancetest— tests onlydocs— documentation onlyci— workflows or build toolingrelease— bumps the version or rolls up a distributionchore— anything elseDescription of your pull request and other information
Part of #1660 (the scheduled monitor follows); folds in #1661.
.github/python-versions.tomlgives each CPython and PyPy version one line: its tier and, whereubuntu-latestcannot provide it, its runner. It nameslatest(3.15) and lists the three pins kept off the file, each with its reason in a comment: both conda!= '3.15'checks and pypcap-parity'sAPT_CACHE_SAVE. TOML, for comments: stdlibtomllib, and the repo's existing config format.util/python_versions.pyruns on the runner's ownpython3:tomllibneeds 3.11, and every image that runs it has 3.12 or newer (runner-images READMEs at2c421200c). Every matrix, engine-tests' interpreter lists and the release completeness counts now come from its outputs, and so does every single-interpreter job's version.Gate (full suite, Python 3.14), which becomes3.15. No required check reads it.0bc157660, on setup-python's own 3.14.8 and 3.15.0 builds, pylint 4.1.3 (astroid 4.3.4, both latest on PyPI) reports the same messages, 515 C / 71 E / 4970 W, with E1101 at 12 on both. Only R0401 cyclic-import differs, and it differs between runs on one interpreter too. bandit, mypy and vermin print identical reports. The crash and the 35 E1101 recorded earlier came from faking a missing_decimalwithsys.modules['_decimal'] = None. That reproduces them on 3.14.8 as well. setup-python's 3.15.0 has no_decimal, and it does not crash.tests/project/test_python_versions_1660.py: the file reproduces1024109fc's matrices except the coverage leg; no workflow pins a version the file does not list; the classifiers, README, SECURITY.md, docs and bug template agree with it. The fix(conda): the Python 3.10 conda build fails since soupsieve 3 was pinned #1633 and ci: a failed KTLO leg turns main and pull requests red; report it as a warning and exit 0 #1672 tier tests now read the file. Tests that read it skip on the KTLO legs (3.8-3.10), which have notomllib. Each new test fails onorigin/mainand passes here. actionlint 1.7.12 reports the same 28 findings as on main.pypiKTLO leg still needs its ownktlo_*output, and the tests name it.