From ec06cea6a551fd39c0c42c9af9660df1b19acf24 Mon Sep 17 00:00:00 2001 From: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Date: Fri, 17 Jan 2025 01:49:46 +0100 Subject: [PATCH] Use Github action arm runner for aarch64 builds (#89) --- .github/workflows/build.yml | 9 +++------ cibuildwheel.toml | 14 -------------- mypy_commit | 2 +- 3 files changed, 4 insertions(+), 21 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9ece558d..64a105cb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -29,8 +29,10 @@ jobs: run: | MATRIX=$( { - cibuildwheel --config-file=cibuildwheel.toml --print-build-identifiers --platform linux mypy \ + cibuildwheel --config-file=cibuildwheel.toml --print-build-identifiers --platform linux --archs x86_64 mypy \ | pyp 'json.dumps({"only": x, "os": "ubuntu-latest"})' \ + && cibuildwheel --config-file=cibuildwheel.toml --print-build-identifiers --platform linux --archs aarch64 mypy \ + | pyp 'json.dumps({"only": x, "os": "ubuntu-24.04-arm"})' \ && cibuildwheel --config-file=cibuildwheel.toml --print-build-identifiers --platform macos mypy \ | pyp 'json.dumps({"only": x, "os": "macos-latest"})' \ && cibuildwheel --config-file=cibuildwheel.toml --print-build-identifiers --platform windows mypy \ @@ -39,7 +41,6 @@ jobs: ) echo "include=$MATRIX" | tee -a $GITHUB_OUTPUT env: - CIBW_ARCHS_LINUX: x86_64 aarch64 CIBW_ARCHS_MACOS: x86_64 arm64 CIBW_ARCHS_WINDOWS: AMD64 @@ -53,10 +54,6 @@ jobs: include: ${{ fromJson(needs.generate_wheels_matrix.outputs.include) }} steps: - - uses: docker/setup-qemu-action@v2 - if: runner.os == 'Linux' - with: - platforms: arm64 - uses: actions/checkout@v4 - name: Checkout mypy shell: bash diff --git a/cibuildwheel.toml b/cibuildwheel.toml index 866c5b01..c071c739 100644 --- a/cibuildwheel.toml +++ b/cibuildwheel.toml @@ -85,17 +85,3 @@ before-test = [ "pip install -r {project}/mypy/test-requirements.txt", ] environment = { MYPYC_OPT_LEVEL="3", MYPYC_DEBUG_LEVEL="0", CC="clang" } - -[[tool.cibuildwheel.overrides]] -select = "*linux_aarch64" -# Only run testcheck, since the other tests are slow and can be flaky (because of TimeoutError). -test-command = """ \ - ( \ - DIR=$(python -c 'import mypy, os; dn = os.path.dirname; print(dn(dn(mypy.__path__[0])))') \ - && cp '{project}/mypy/pyproject.toml' '{project}/mypy/conftest.py' $DIR \ -\ - && MYPY_TEST_DIR=$(python -c 'import mypy.test; print(mypy.test.__path__[0])') \ -\ - && MYPY_TEST_PREFIX='{project}/mypy' pytest $MYPY_TEST_DIR/testcheck.py \ - ) -""" diff --git a/mypy_commit b/mypy_commit index 92c74cd4..fb1653ef 100644 --- a/mypy_commit +++ b/mypy_commit @@ -1 +1 @@ -499adaed8adbded1a180e30d071438fef81779ec +8859d5163fc6bd16c2161e24fcf2677e3d6479e1