From 99bc30bc619da2b8cd96cf96d34368f0bd6590e0 Mon Sep 17 00:00:00 2001 From: Corentin Le Molgat Date: Fri, 27 Oct 2023 14:35:11 +0200 Subject: [PATCH] tools/release: fix distutils.get_platform() usage. deprecated -> replaced by platform.platform() --- tools/release/build_delivery_linux.sh | 2 +- tools/release/build_delivery_macos.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/release/build_delivery_linux.sh b/tools/release/build_delivery_linux.sh index d1364ddb88..e198a6aec9 100755 --- a/tools/release/build_delivery_linux.sh +++ b/tools/release/build_delivery_linux.sh @@ -206,7 +206,7 @@ function build_python() { # Check Python env echo "check python3..." command -v python3 | xargs echo "python3: " | tee -a build.log - python3 -c "import distutils.util as u; print(u.get_platform())" | tee -a build.log + python3 -c "import platform as p; print(p.platform())" | tee -a build.log python3 -m pip install --upgrade --user --break-system-package pip python3 -m pip install --upgrade --user --break-system-package wheel absl-py mypy mypy-protobuf virtualenv echo "check protoc-gen-mypy..." diff --git a/tools/release/build_delivery_macos.sh b/tools/release/build_delivery_macos.sh index a27bb2c0c4..bccc1129c8 100755 --- a/tools/release/build_delivery_macos.sh +++ b/tools/release/build_delivery_macos.sh @@ -229,7 +229,7 @@ function build_python() { echo "check python3..." command -v python3 | xargs echo "python3: " | tee -a build.log command -v "python${PY_VERSION}" | xargs echo "python${PY_VERSION}: " | tee -a build.log - "python${PY_VERSION}" -c "import distutils.util as u; print(u.get_platform())" | tee -a build.log + "python${PY_VERSION}" -c "import platform as p; print(p.platform())" | tee -a build.log "python${PY_VERSION}" -m pip install --upgrade --user pip "python${PY_VERSION}" -m pip install --upgrade --user wheel absl-py mypy mypy-protobuf virtualenv echo "check protoc-gen-mypy..."