From fa8d9428bc49d52ffb82b374093310dda0a23486 Mon Sep 17 00:00:00 2001 From: Azeem Shaik Date: Wed, 29 Jul 2026 19:31:50 +0530 Subject: [PATCH 1/3] Run docs, clippy and MSRV over the whole feature matrix The test job already covered all three feature combinations; docs, lint and msrv each ran only --all-features. That is not a smaller version of the same check, it is a different one: an intra-doc link can point at a feature-gated item and resolve fine under --all-features while breaking every smaller build, and clippy never looks at the code a minimal build actually compiles. This was not hypothetical. A `crate::clock::Clock` link added on the circuit-breaker branch resolved under --all-features and failed rustdoc under --no-default-features --features blocking, where `crate::clock` does not exist. Both CI and my own local gates missed it because both only ever ran the union. Verified against this branch's 0.2.0 code: all three configs pass rustdoc and clippy. --- .github/workflows/ci.yml | 35 +++++++++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e709296..22c3485 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,31 +26,58 @@ jobs: - run: cargo test ${{ matrix.features }} lint: + name: lint (${{ matrix.features }}) runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + features: + - --all-features + - --no-default-features --features async + - --no-default-features --features blocking steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: components: rustfmt, clippy - run: cargo fmt --all --check - - run: cargo clippy --all-targets --all-features -- -D warnings + # Every feature combination, not just the union. A lint that only ever sees `--all-features` + # never looks at the code a minimal build actually compiles. + - run: cargo clippy --all-targets ${{ matrix.features }} -- -D warnings docs: + name: docs (${{ matrix.features }}) runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + features: + - --all-features + - --no-default-features --features async + - --no-default-features --features blocking steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable - - run: cargo doc --all-features --no-deps + # Matrixed because an intra-doc link can point at a feature-gated item and resolve fine + # under `--all-features` while breaking every smaller build. + - run: cargo doc ${{ matrix.features }} --no-deps env: RUSTDOCFLAGS: "-D warnings" msrv: - name: msrv (1.85) + name: msrv 1.85 (${{ matrix.features }}) runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + features: + - --all-features + - --no-default-features --features async + - --no-default-features --features blocking steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@1.85.0 - - run: cargo check --all-features + - run: cargo check ${{ matrix.features }} semver: runs-on: ubuntu-latest From 936ea426e499a1510489219deacf33675f442cac Mon Sep 17 00:00:00 2001 From: Azeem Shaik Date: Sun, 9 Aug 2026 10:42:46 +0530 Subject: [PATCH 2/3] update gitignore to include DS_STORE file --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index c6814fc..510b3f8 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ learning/ # Rust build output /target +.DS_Store From ea196709a67f988cefcad90caf0ae4fa7d89c248 Mon Sep 17 00:00:00 2001 From: Azeem Shaik Date: Sun, 9 Aug 2026 10:44:56 +0530 Subject: [PATCH 3/3] Hold examples and tests to the MSRV, and stop running fmt three times Two things I left in the first pass. `cargo check` compiles neither examples nor test targets, so the MSRV floor was only ever applied to the library. The breaker branch adds examples/breaker.rs, which today's msrv job would never look at. --all-targets covers both. And `cargo fmt --all --check` does not vary by feature, so running it inside a 3-way matrix was two wasted runs. It gets its own job. --- .github/workflows/ci.yml | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22c3485..a617495 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,12 +39,21 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: - components: rustfmt, clippy - - run: cargo fmt --all --check + components: clippy # Every feature combination, not just the union. A lint that only ever sees `--all-features` # never looks at the code a minimal build actually compiles. - run: cargo clippy --all-targets ${{ matrix.features }} -- -D warnings + fmt: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable + with: + components: rustfmt + # Formatting does not vary by feature, so this is one job rather than a matrix. + - run: cargo fmt --all --check + docs: name: docs (${{ matrix.features }}) runs-on: ubuntu-latest @@ -77,7 +86,9 @@ jobs: steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@1.85.0 - - run: cargo check ${{ matrix.features }} + # --all-targets so examples and tests are held to the MSRV too; a plain `cargo check` + # compiles neither. + - run: cargo check --all-targets ${{ matrix.features }} semver: runs-on: ubuntu-latest