@@ -17,12 +17,23 @@ jobs:
1717 platform :
1818 - { runner: ubuntu-latest, python_exec: ".venv/bin/python" }
1919 - { runner: ubuntu-24.04-arm, python_exec: ".venv/bin/python" }
20- - { runner: macos-latest, python_exec: ".venv/bin/python" }
21- - { runner: macos-13, python_exec: ".venv/bin/python" }
20+ - { runner: macos-latest, python_exec: ".venv/bin/python", extra_rustflags: "-C split-debuginfo=off" }
21+ - { runner: macos-13, python_exec: ".venv/bin/python", extra_rustflags: "-C split-debuginfo=off" }
2222 - { runner: windows-latest, python_exec: ".venv\\Scripts\\python" }
2323 runs-on : ${{ matrix.platform.runner }}
24+ env :
25+ RUSTFLAGS : " -C debuginfo=0 ${{ matrix.platform.extra_rustflags }}"
26+ CARGO_INCREMENTAL : " 0"
27+ SCCACHE_GHA_ENABLED : " true"
28+ RUSTC_WRAPPER : " sccache"
29+
2430 steps :
2531 - uses : actions/checkout@v4
32+ with :
33+ fetch-depth : 1
34+
35+ - name : Run sccache-cache
36+ uses :
mozilla-actions/[email protected] 2637
2738 - uses : actions/setup-python@v5
2839 id : setup_python
@@ -31,23 +42,21 @@ jobs:
3142 cache : ' pip'
3243
3344 - run : rustup toolchain install stable --profile minimal
45+
3446 - name : Rust Cache
3547 uses : Swatinem/rust-cache@v2
3648 with :
3749 key : rust-${{ matrix.platform.runner }}-${{ matrix.python-version }}
50+ cache-targets : ' false'
51+ cache-all-crates : ' false'
52+ cache-workspace-crates : ' false'
53+
3854 - name : Rust tests (no default features)
3955 run : cargo test --no-default-features --verbose
4056
4157 - name : Rust tests
4258 run : cargo test --verbose
4359
44- - uses : actions/cache@v4
45- with :
46- path : .venv
47- key : pyenv-${{ matrix.platform.runner }}-${{ steps.setup_python.outputs.python-version }}-${{ hashFiles('pyproject.toml') }}
48- restore-keys : |
49- pyenv-${{ matrix.platform.runner }}-${{ steps.setup_python.outputs.python-version }}-
50-
5160 - name : Setup venv
5261 run : |
5362 python -m venv .venv
5665 ${{ matrix.platform.python_exec }} -m pip install maturin mypy pytest pytest-asyncio
5766 - name : Python build
5867 run : |
59- ${{ matrix.platform.python_exec }} -m maturin develop -E all
68+ ${{ matrix.platform.python_exec }} -m maturin develop --strip - E all
6069 - name : Python type check (mypy)
6170 run : |
6271 ${{ matrix.platform.python_exec }} -m mypy python
6877 runs-on : ubuntu-latest
6978 steps :
7079 - uses : actions/checkout@v4
80+ with :
81+ fetch-depth : 1
7182 - name : Install Rust toolchain
7283 uses : dtolnay/rust-toolchain@stable
7384 - uses : taiki-e/install-action@v2
0 commit comments