fix: add genereate-import-lib to pyo3 #158
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
| on: | |
| push: | |
| branches: | |
| - main | |
| - release | |
| pull_request: | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@nightly | |
| with: | |
| toolchain: nightly | |
| components: clippy, rustfmt | |
| - name: Lint | |
| run: make lint | |
| run_tests: | |
| strategy: | |
| matrix: | |
| os: [macos-latest, ubuntu-latest] | |
| python-version: ['3.10', '3.11', '3.12', '3.13', '3.14'] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v4 | |
| id: setup-python | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install Rust Toolchain | |
| run: rustup toolchain install stable --profile minimal --no-self-update | |
| - name: Install requirements | |
| run: | | |
| python -m venv venv | |
| source venv/bin/activate | |
| pip install maturin | |
| pip install -r tests/requirements.txt | |
| maturin develop | |
| - name: Run tests | |
| run: | | |
| source venv/bin/activate | |
| python -m pytest --cov-report=xml:coverage.xml --cov=. --junitxml=unit.junit.xml | |
| - name: Upload results to codecov | |
| if: ${{ !cancelled() }} | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| token: ${{ secrets.CODECOV_ORG_TOKEN }} | |
| url: ${{ secrets.CODECOV_URL }} | |
| files: unit.junit.xml | |
| disable_search: true | |
| report_type: test_results | |
| - name: Upload results to codecov (Staging) | |
| if: ${{ !cancelled() }} | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| token: ${{ secrets.CODECOV_ORG_TOKEN_STAGING }} | |
| url: ${{ secrets.CODECOV_STAGING_API_URL }} | |
| files: unit.junit.xml | |
| disable_search: true | |
| report_type: test_results |