From 06d4eafe837e091e28283fa225695d90522201ee Mon Sep 17 00:00:00 2001 From: arty Date: Mon, 4 Dec 2023 10:03:12 -0800 Subject: [PATCH] Use the existing built wheel in the python tests. Add a check for incompatible wheels before uploading --- .github/workflows/build-test.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index c5a5ef7d..1cc52fcf 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -145,7 +145,11 @@ jobs: run: | . ./activate cargo build - pip install . + # This finds and installs a compatible wheel from the target directory on linux. + # We do it here as a hedge against changes in the python environment that might + # have happened due to pulling in the trunk versions of other packages that + # depend on clvm_tools_rs. + python support/wheelname.py pip install clvm_rs pip install clvm_tools cd resources/tests && python test_clvm_step.py && python mandelbrot-cldb.py @@ -281,6 +285,13 @@ jobs: name: wheels path: ./target/wheels/ + - name: Check for incompatible wheels and bail if found + run: | + set -e + # Check for a wheel with -linux_x86_64 platform tag, which will + # fail uploading to pypi. + find target -name \*-linux_x86_64.whl -exec /bin/false '{}' '+' + - name: Publish distribution to PyPI if: env.RELEASE == 'true' uses: pypa/gh-action-pypi-publish@release/v1