Optimize trace callback performance (Issue #115) #773
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build source and binary wheels | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| release: | |
| types: | |
| - published | |
| workflow_dispatch: | |
| jobs: | |
| build_wheels: | |
| name: Build wheels on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| # Check this table to update os versions: | |
| # https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories | |
| os: [ubuntu-24.04, windows-2022, macos-14] | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Build wheels | |
| env: | |
| CIBW_BUILD: cp{38,39,310,311,312,313,314}-* | |
| CIBW_ARCHS_LINUX: x86_64 | |
| # At some point, build will replace pip as the default | |
| # (https://cibuildwheel.pypa.io/en/stable/options/#build-frontend): | |
| CIBW_BUILD_FRONTEND: "build" | |
| CIBW_ARCHS_MACOS: "x86_64 arm64 universal2" | |
| CIBW_TEST_EXTRAS: "dev" | |
| CIBW_TEST_REQUIRES: "pytest" | |
| CIBW_TEST_COMMAND: pytest {project}/crosshair -m smoke | |
| CIBW_BUILD_VERBOSITY: 1 | |
| # Skip tests: | |
| # * linuxes don't have corresponding z3 binary builds | |
| # * 3.13+ in win32, which has a numpy build error rn | |
| # * 3.8 which can't run our current version of mypy | |
| CIBW_TEST_SKIP: "*-*linux_{i686,aarch64,ppc64le,s390x} *-musllinux* cp3{13,14}-win* cp38*" | |
| uses: pypa/cibuildwheel@v3.2.0 | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} | |
| path: ./wheelhouse/*.whl | |
| build_sdist: | |
| name: Build source distribution | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Install dependencies | |
| run: python -m pip install --upgrade build | |
| - name: Build sdist | |
| run: python -m build --sdist | |
| - name: Test sdist build | |
| run: pipx install --verbose dist/*.tar.gz | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: cibw-sdist | |
| path: dist/*.tar.gz | |
| upload_pypi: | |
| # Publish when a GitHub Release is created: | |
| needs: [build_wheels, build_sdist] | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: release | |
| url: https://pypi.org/p/crosshair-tool | |
| permissions: | |
| id-token: write | |
| if: (github.event_name == 'workflow_dispatch') || (github.event_name == 'release' && github.event.action == 'published') | |
| steps: | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| pattern: cibw-* | |
| path: dist | |
| merge-multiple: true | |
| - uses: pypa/gh-action-pypi-publish@v1.13.0 | |
| with: | |
| verbose: true | |
| attestations: false |