From 9213fce8821f994518490f49fba8ce0c48f9d916 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 26 Feb 2026 21:43:31 +0000 Subject: [PATCH 1/2] Update GitHub Artifact Actions --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 36d0be1..5c83d1d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -60,7 +60,7 @@ jobs: python setup.py sdist - name: Upload build artifacts - uses: actions/upload-artifact@v6 + uses: actions/upload-artifact@v7 with: name: wheelstorage-${{ matrix.os }} path: ./dist/* @@ -93,7 +93,7 @@ jobs: shell: bash - name: Download release assets for ${{ matrix.os }} - uses: actions/download-artifact@v7 + uses: actions/download-artifact@v8 with: name: wheelstorage-${{ matrix.os }} path: dist From 0b0a83732ce9f247336ad7c662e986f45460ef9c Mon Sep 17 00:00:00 2001 From: Miguel Sousa Date: Wed, 20 May 2026 16:30:15 -0700 Subject: [PATCH 2/2] Replace distutils mkpath/remove_tree with stdlib equivalents Recent setuptools releases reworked setuptools._distutils.dir_util so its mkpath() and remove_tree() singledispatch wrappers no longer accept the distutils-era verbose= / dry_run= keyword arguments, causing the "Download OTS source" CI step to fail with: TypeError: mkpath() got an unexpected keyword argument 'dry_run' Switch to os.makedirs(..., exist_ok=True) and shutil.rmtree(...), guarded by self.dry_run, which removes the dependency on a setuptools-internal API. --- setup.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/setup.py b/setup.py index abde01f..466ce2d 100644 --- a/setup.py +++ b/setup.py @@ -1,8 +1,8 @@ -from distutils.dir_util import mkpath, remove_tree from distutils import log import io import os import re +import shutil from pathlib import Path from setuptools import setup, Extension, Command from setuptools.command import build_py @@ -182,16 +182,18 @@ def run(self): output_dir = os.path.join(self.download_dir, "ots") if self.clean and os.path.isdir(output_dir): - remove_tree(output_dir, verbose=self.verbose, dry_run=self.dry_run) + log.info("removing '{}'".format(output_dir)) + if not self.dry_run: + shutil.rmtree(output_dir) if os.path.isdir(output_dir): log.info("{} was already downloaded".format(output_dir)) else: archive_name = self.url.rsplit("/", 1)[-1] - mkpath(self.download_dir, - verbose=self.verbose, - dry_run=self.dry_run) + log.info("creating '{}'".format(self.download_dir)) + if not self.dry_run: + os.makedirs(self.download_dir, exist_ok=True) log.info("downloading {}".format(self.url)) if not self.dry_run: