From a20307b2b93893861d284d4f25c8bf9325287ef6 Mon Sep 17 00:00:00 2001 From: Nate Prewitt Date: Fri, 26 Jul 2024 13:59:54 -0600 Subject: [PATCH] Update setuptools --- requirements-dev.txt | 3 ++- scripts/ci/install-dev-deps | 9 ++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/requirements-dev.txt b/requirements-dev.txt index 6141c927faa..609c1d4324c 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,6 +1,7 @@ wheel==0.43.0 coverage==7.2.7 -setuptools==67.8.0;python_version>="3.12" +setuptools==71.1.0;python_version>="3.12" +packaging==23.2;python_versions>="3.12" # Requirement for setuptools>=71 # Pytest specific deps pytest==8.1.1 diff --git a/scripts/ci/install-dev-deps b/scripts/ci/install-dev-deps index 7477376430e..d5b4d5569fe 100755 --- a/scripts/ci/install-dev-deps +++ b/scripts/ci/install-dev-deps @@ -27,5 +27,12 @@ def run(command): if __name__ == "__main__": with cd(REPO_ROOT): if sys.version_info[:2] >= (3, 12): - run("pip install setuptools") + # Python 3.12+ no longer includes setuptools by default. + + # Setuptools 71+ now perfers already installed versions + # of packaging _and_ broke the API for packaging<22.0. + # We'll pin to match what's in requirements-dev.txt. + run( + "pip install setuptools==71.1.0 packaging==23.2" + ) run("pip install -r requirements-dev-lock.txt")