ci: fix Build & verify and coverage on 3.14 - #338
Merged
Conversation
v3.0.0 ships twine 7, which accepts metadata 2.5. flit-core now writes Metadata-Version 2.5, so "twine check --strict" in the older twine 6 rejected our own wheel and the "Build & verify" job failed. v3.0.1 also runs its tool installation in a different directory and unsets UV_EXCLUDE_NEWER, so our [tool.uv] exclude-newer no longer applies to the build tools. Assisted-by: ClaudeCode:claude-opus-5
sysmon, the default coverage core on Python 3.14+, cannot record dynamic contexts. Remove --cov-context=test and html.show_contexts; only the per-line "which tests covered this" view in the local HTML report is lost. Assisted-by: ClaudeCode:claude-opus-5
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.
🤖 AI text below 🤖
Two changes are needed together to make CI green.
1. Bump build-and-inspect-python-package to v3.0.1
Build & verifyfails onmain:twine check --strictrejects our own wheel withInvalidDistribution: Invalid distribution metadata: '2.5' is not a valid metadata version. flit-core now writesMetadata-Version: 2.5, and the pinned action shipped twine 6, which does not know that version.baipp v3.0.0 bumps to twine 7, which adds support for metadata 2.5 and PEP 794. v3.0.1 also moves the tool installation to a separate directory and unsets
UV_EXCLUDE_NEWER, so our[tool.uv] exclude-newerno longer leaks into the build tools.Verified locally that twine 6.2.0 rejects our wheel and twine 7.0.0 passes it, with packaging held at the 26.2 the action pins. The v3 line no longer force-tags moving
@v3tags, so the full commit hash pin stays as is; the artifact is still namedPackages, so the download step needs no change.2. Drop coverage dynamic contexts
sysmon, the default coverage core on Python 3.14 and later, cannot record dynamic contexts, so the test runs fail there. This removes--cov-context=testfrom both nox sessions andhtml.show_contextsfrompyproject.toml.The alternative was to pin
run.core = "ctrace"(as pypa/build did), but that gives up the sysmon speedup. Coverage totals and the Codecov XML do not change; only the per-line "which tests covered this" view in the local HTML report is lost.