|
1 | 1 | name: CI |
2 | 2 |
|
3 | | -# No push trigger for `dev`: everything on dev travels through a pull |
4 | | -# request anyway, and a push run would twin the PR run on the same commit — |
5 | | -# under *required* checks, a deduplicating cancellation poisons the gate |
6 | | -# (a cancelled twin's "CI is green" reads as failure and blocks the merge). |
7 | | -# `main` keeps its push trigger because a rebase-merge mints a new SHA that |
8 | | -# no PR run ever checked. |
| 3 | +# No push trigger at all: everything travels through a pull request, and |
| 4 | +# main only ever receives a SQUASH of a green PR — the squashed tree is |
| 5 | +# byte-identical to the PR head the checks already ran on, so a main |
| 6 | +# re-run would test the same content twice. Merging runs release.yml |
| 7 | +# alone; workflow_dispatch stays as the manual escape hatch. |
9 | 8 | on: |
10 | | - push: |
11 | | - branches: [main] |
12 | 9 | pull_request: |
13 | 10 | workflow_dispatch: |
14 | 11 |
|
|
29 | 26 | RUST_BACKTRACE: 1 |
30 | 27 |
|
31 | 28 | jobs: |
| 29 | + conformance: |
| 30 | + name: the three languages agree |
| 31 | + runs-on: ubuntu-latest |
| 32 | + timeout-minutes: 20 |
| 33 | + steps: |
| 34 | + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 |
| 35 | + # The engine's conformance cases, at a PINNED ref: bumping the pin is |
| 36 | + # a visible PR diff, which is the point — semantics move only when |
| 37 | + # somebody says so. |
| 38 | + - run: | |
| 39 | + ref="v0.8.0" # the engine release these wheels build against |
| 40 | + curl -sSL "https://github.com/dynamic-config-rs/dynamic-config/archive/refs/tags/${ref}.tar.gz" \ |
| 41 | + | tar -xz --strip-components=1 --wildcards '*/conformance/' |
| 42 | + - uses: actions/setup-python@2e3e4b15a884dc73a63f962bff250a855150a234 # v6 |
| 43 | + with: |
| 44 | + python-version: "3.12" |
| 45 | + - run: pip install dynamic-config-py |
| 46 | + - run: CONFORMANCE_DIR=conformance/cases python scripts/conformance.py |
| 47 | + |
| 48 | + msrv: |
| 49 | + name: the declared floor compiles |
| 50 | + runs-on: ubuntu-latest |
| 51 | + timeout-minutes: 30 |
| 52 | + steps: |
| 53 | + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 |
| 54 | + - uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 # master |
| 55 | + with: |
| 56 | + toolchain: stable |
| 57 | + # The stores reach `etcd-client`, whose build script compiles protos. |
| 58 | + - run: sudo apt-get update && sudo apt-get install -y protobuf-compiler |
| 59 | + # A lockfile resolved by stable, then checked by the floor — the |
| 60 | + # combination `pip install` + our build actually produces. This job |
| 61 | + # did not exist before the 1.88 raise; a floor nobody compiles |
| 62 | + # against is a number in a manifest. |
| 63 | + - run: cargo generate-lockfile |
| 64 | + - uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772 # master |
| 65 | + with: |
| 66 | + toolchain: "1.88" |
| 67 | + - uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2 |
| 68 | + with: |
| 69 | + shared-key: msrv |
| 70 | + - run: cargo +1.88 check -p dynamic-config-python --locked --lib |
| 71 | + - run: cargo +1.88 check -p dynamic-config-python-remote --locked --lib |
| 72 | + |
32 | 73 | # What changed, so the expensive jobs below can sit out a run that cannot |
33 | 74 | # affect them. Deliberately a *job* rather than `on.pull_request.paths`: |
34 | 75 | # a workflow filtered out at the trigger never reports at all, and a |
@@ -419,6 +460,8 @@ jobs: |
419 | 460 | - python-free-threaded |
420 | 461 | - docs-links |
421 | 462 | - actionlint |
| 463 | + - msrv |
| 464 | + - conformance |
422 | 465 | if: always() |
423 | 466 | runs-on: ubuntu-latest |
424 | 467 | timeout-minutes: 5 |
|
0 commit comments