tools/release: fix distutils.get_platform() usage.
deprecated -> replaced by platform.platform()
This commit is contained in:
@@ -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..."
|
||||
|
||||
@@ -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..."
|
||||
|
||||
Reference in New Issue
Block a user