From 7d0efd73df4f5ce4064e7d10fc0e1b8dab38c9ed Mon Sep 17 00:00:00 2001 From: Benjamin Gilbert Date: Tue, 29 Oct 2024 12:01:17 -0700 Subject: [PATCH] setuptools 69.3+ normalizes sdist name to openslide_python Current versions of setuptools normalize the filename of the source tarball and of its toplevel directory to openslide_python-* per PEP 625. This is an intentional ecosystem-wide change, so adapt to it rather than trying to undo it. Signed-off-by: Benjamin Gilbert --- .github/workflows/python.yml | 8 ++++---- CHANGELOG.md | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 307b61ab..3adaf2eb 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -283,14 +283,14 @@ jobs: run: | version=$(echo "${{ github.ref_name }}" | sed "s/^v//") # recompress tarball with xz - gunzip -k "${{ needs.pre-commit.outputs.dist-base }}/openslide-python-${version}.tar.gz" - tar xf "${{ needs.pre-commit.outputs.dist-base }}/openslide-python-${version}.tar" - xz -9 "${{ needs.pre-commit.outputs.dist-base }}/openslide-python-${version}.tar" + gunzip -k "${{ needs.pre-commit.outputs.dist-base }}/openslide_python-${version}.tar.gz" + tar xf "${{ needs.pre-commit.outputs.dist-base }}/openslide_python-${version}.tar" + xz -9 "${{ needs.pre-commit.outputs.dist-base }}/openslide_python-${version}.tar" # extract changelog awk -e '/^## / && ok {exit}' \ -e '/^## / {ok=1; next}' \ -e 'ok {print}' \ - "openslide-python-$version/CHANGELOG.md" > changes + "openslide_python-$version/CHANGELOG.md" > changes gh release create --latest --verify-tag \ --repo "${{ github.repository }}" \ --title "OpenSlide Python $version" \ diff --git a/CHANGELOG.md b/CHANGELOG.md index fcd632ac..f348fce6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ ### Changes * Drop wheel for 32-bit Windows +* Rename source distribution to `openslide_python` per [PEP 625][] * Require `AbstractSlide` subclasses to implement all abstract methods * Provide default `AbstractSlide.set_cache()` implementation * Switch to [PEP 621][] project metadata @@ -29,6 +30,7 @@ * docs: Fix types of properties that return tuples of items [installed from PyPI]: https://pypi.org/project/openslide-bin/ +[PEP 625]: https://peps.python.org/pep-0625/ [PEP 621]: https://peps.python.org/pep-0621/ [Python filesystem encoding]: https://docs.python.org/3/glossary.html#term-filesystem-encoding-and-error-handler