@@ -2,11 +2,12 @@ name: Polars CI
22
33on :
44 pull_request :
5- types : [review_requested, ready_for_review, synchronize ]
5+ types : [review_requested, ready_for_review]
66 paths :
77 - " .github/workflows/polars-*.yml"
88 - " Cargo.toml"
99 - " Makefile"
10+ - " core/**"
1011 - " polars/**"
1112
1213concurrency :
@@ -17,82 +18,42 @@ permissions:
1718 contents : read
1819
1920jobs :
20- preflight :
21- runs-on : ubuntu-latest
22- permissions :
23- contents : read
24- pull-requests : read
25- outputs :
26- validate : ${{ steps.filter.outputs.validate }}
27- steps :
28- - uses : dorny/paths-filter@d1c1ffe0248fe513906c8e24db8ea791d46f8590
29- id : filter
30- with :
31- filters : |
32- validate:
33- - "Cargo.toml"
34- - "Makefile"
35- - "polars/**"
36-
3721 validate :
38- needs : preflight
39- if : ${{ always() }}
4022 runs-on : ubuntu-latest
4123 defaults :
4224 run :
4325 shell : bash
4426 steps :
45- - name : Fail if preflight did not succeed
46- if : ${{ needs.preflight.result != 'success' }}
47- run : |
48- echo "preflight job did not succeed: ${{ needs.preflight.result }}"
49- exit 1
50-
51- - name : Skip validation for non-polars changes
52- if : ${{ needs.preflight.result == 'success' && needs.preflight.outputs.validate != 'true' }}
53- run : echo "Skipping Polars CI validate job because this PR does not touch Cargo.toml, Makefile, or polars/**."
54-
55- - if : ${{ needs.preflight.outputs.validate == 'true' }}
56- uses : actions/checkout@v6
57- - if : ${{ needs.preflight.outputs.validate == 'true' }}
58- uses : actions/setup-python@v6
27+ - uses : actions/checkout@v6
28+ - uses : actions/setup-python@v6
5929 with :
6030 python-version : " 3.10"
61- - if : ${{ needs.preflight.outputs.validate == 'true' }}
62- uses : astral-sh/setup-uv@v8.0.0
63- - if : ${{ needs.preflight.outputs.validate == 'true' }}
64- uses : dtolnay/rust-toolchain@stable
31+ - uses : astral-sh/setup-uv@v8.0.0
32+ - uses : dtolnay/rust-toolchain@stable
6533
6634 - name : Sync polars dependencies
67- if : ${{ needs.preflight.outputs.validate == 'true' }}
6835 working-directory : polars
6936 run : uv sync --group dev --no-install-project
7037
7138 - name : Test techr-core
72- if : ${{ needs.preflight.outputs.validate == 'true' }}
7339 run : cargo test -p techr-core
7440
7541 - name : Build local extension for tests
76- if : ${{ needs.preflight.outputs.validate == 'true' }}
7742 working-directory : polars
7843 run : uv run maturin develop --uv
7944
8045 - name : Test polars package
81- if : ${{ needs.preflight.outputs.validate == 'true' }}
8246 working-directory : polars
8347 run : uv run pytest
8448
8549 - name : Build wheel and sdist
86- if : ${{ needs.preflight.outputs.validate == 'true' }}
8750 working-directory : polars
8851 run : uv run maturin build --release --sdist --out dist
8952
9053 - name : Check artifact contents
91- if : ${{ needs.preflight.outputs.validate == 'true' }}
9254 run : python polars/scripts/check_artifacts.py polars/dist
9355
9456 - name : Smoke test built wheel
95- if : ${{ needs.preflight.outputs.validate == 'true' }}
9657 run : |
9758 wheel="$(python - <<'PY'
9859 from pathlib import Path
0 commit comments