Repository navigation
Fix deprecated setup.py commands, broken publish job, and README drift - #133
Open
scottclowe wants to merge 13 commits into
Open
scottclowe wants to merge 13 commits into
scottclowe wants to merge 13 commits into
Conversation
The setuptools test command has been removed, and invoking setup.py directly is deprecated. Building currently warns that references to the test command will cause build errors in the future. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The schedule event does not accept a branches key; scheduled runs always use the default branch. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Wheels continue to be built on every OS and Python version, in case the package contains compiled extensions. The sdist is built once, in the publish job. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
download-artifact@v4 matches multiple artifacts with pattern, not name, and needs merge-multiple to put them all into one directory. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Replace the API token with OIDC-based Trusted Publishing, and update the deprecated repository_url input to repository-url. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Yanking a release is straightforward. The real hazard is that a version number can never be reused once it has been uploaded. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Note that wheels are identical for pure-Python packages, and that packages with compiled extensions need manylinux wheels for PyPI. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This branch has not been deployed
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.
Summary
Fixes several things in the template that are broken, deprecated, or out of date.
Packaging
testanduploadcustom commands fromsetup.py. The setuptoolstestcommand has been removed, and building with current setuptools (84.0.0) warns that references to it will cause build errors in the future.pip install --editable .andpython -m buildinstead of invokingsetup.pydirectly.CI
test.yaml: remove thebrancheskey underschedule. It is not valid there, and scheduled runs always use the default branch.test-release-candidate.yaml:macos-latest/ 3.12 matrix entry.python -m build --wheel. Wheels are still built on every OS and Python version, since a package made from the template may contain compiled extensions. The sdist is now built once, in the publish job.publishjob's artifact download.download-artifact@v4needspattern: wheel-*withmerge-multiple: true;name: wheel-*matches nothing.id-token: write,testpypienvironment) instead of an API token, and replace the deprecatedrepository_urlinput withrepository-url.Docs
black_nbconvertreference with nbQA, which is what the pre-commit config actually uses.lintworkflow (the README said five workflows; there are four).Testing
python -m buildsucceeds with setuptools 84.0.0, with no test-command deprecation warning.setup.pycompiles at every commit.publishjob is still disabled by default, and enabling it requires registering a trusted publisher on Test PyPI first.🤖 Generated with Claude Code