Skip to content

Commit b032bcb

Browse files
fix: minimal versions selection
Also adds this to CI closes #85
1 parent 40bf6c3 commit b032bcb

File tree

2 files changed

+76
-6
lines changed

2 files changed

+76
-6
lines changed

.github/workflows/tests.yaml

Lines changed: 70 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ jobs:
111111
- name: list ignored tests
112112
run: |
113113
cargo nextest list --workspace ${{ env.FEATURES }} --lib --bins --tests --run-ignored ignored-only
114-
env:
114+
env:
115115
NEXTEST_NO_TESTS: "pass"
116116

117117
- name: run tests
@@ -224,7 +224,7 @@ jobs:
224224
RUST_LOG: ${{ runner.debug && 'TRACE' || 'DEBUG'}}
225225
NEXTEST_EXPERIMENTAL_LIBTEST_JSON: 1
226226
NEXTEST_NO_TESTS: "pass"
227-
227+
228228
- name: upload results
229229
if: ${{ failure() && inputs.flaky }}
230230
uses: actions/upload-artifact@v6
@@ -233,3 +233,71 @@ jobs:
233233
path: output
234234
retention-days: 1
235235
compression-level: 0
236+
237+
minimal-crates:
238+
runs-on: ${{ matrix.runner }}
239+
strategy:
240+
fail-fast: false
241+
matrix:
242+
name: [ubuntu-latest, macOS-arm-latest] # TODO: windows
243+
include:
244+
- name: ubuntu-latest
245+
os: ubuntu-latest
246+
release-os: linux
247+
release-arch: amd64
248+
runner: [self-hosted, linux, X64]
249+
- name: macOS-arm-latest
250+
os: macOS-latest
251+
release-os: darwin
252+
release-arch: aarch64
253+
runner: [self-hosted, macOS, ARM64]
254+
steps:
255+
- uses: actions/checkout@v6
256+
- uses: dtolnay/rust-toolchain@nightly
257+
- name: cargo check
258+
run: |
259+
rm -f Cargo.lock
260+
cargo +nightly check -Z minimal-versions --workspace --all-features --lib --bins
261+
262+
minimal-crates-windows:
263+
timeout-minutes: 30
264+
name: "Minimal Crates (Windows)"
265+
runs-on: ${{ matrix.runner }}
266+
strategy:
267+
fail-fast: false
268+
matrix:
269+
name: [windows-latest]
270+
rust: ["${{ inputs.rust-version}}"]
271+
target:
272+
- x86_64-pc-windows-msvc
273+
include:
274+
- name: windows-latest
275+
os: windows
276+
runner: [self-hosted, windows, x64]
277+
env:
278+
# Using self-hosted runners so use local cache for sccache and
279+
# not SCCACHE_GHA_ENABLED.
280+
RUSTC_WRAPPER: "sccache"
281+
steps:
282+
- name: Checkout
283+
uses: actions/checkout@v6
284+
with:
285+
ref: ${{ inputs.git-ref }}
286+
287+
- name: Install Rust nightly
288+
run: |
289+
rustup toolchain install nightly
290+
rustup target add ${{ matrix.target }}
291+
rustup set default-host ${{ matrix.target }}
292+
293+
- name: Install sccache
294+
uses: mozilla-actions/sccache-action@v0.0.9
295+
296+
- uses: msys2/setup-msys2@v2
297+
with:
298+
release: false
299+
300+
- name: cargo check
301+
run: |
302+
rm -Force Cargo.lock
303+
cargo +nightly check -Z minimal-versions --workspace --all-features --lib --bins

Cargo.toml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ unused-async = "warn"
3333
iroh-metrics-derive = { path = "./iroh-metrics-derive", version = "0.4.0" }
3434
itoa = "1"
3535
ryu = "1"
36-
serde = { version = "1", features = ["derive", "rc"] }
37-
n0-error = "0.1.0"
38-
tracing = "0.1"
36+
serde = { version = "1.0.228", features = ["derive", "rc"] }
37+
n0-error = "0.1.3"
38+
tracing = "0.1.44"
3939

4040
# static_core feature
4141
erased_set = { version = "0.8", optional = true }
@@ -44,7 +44,8 @@ erased_set = { version = "0.8", optional = true }
4444
http-body-util = { version = "0.1.0", optional = true }
4545
hyper = { version = "1", features = ["server", "http1"], optional = true }
4646
hyper-util = { version = "0.1.17", features = ["tokio"], optional = true }
47-
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls"], optional = true }
47+
reqwest = { version = "0.13", default-features = false, features = ["json", "rustls-no-provider"], optional = true }
48+
rustls = { version = "0.23", default-features = false, features = ["std", "ring"], optional = true }
4849
tokio = { version = "1", features = ["rt", "net", "fs"], optional = true }
4950
postcard = { version = "1.1.1", features = ["use-std"] }
5051

@@ -68,6 +69,7 @@ service = [
6869
"dep:hyper-util",
6970
"dep:reqwest",
7071
"dep:tokio",
72+
"dep:rustls",
7173
]
7274
# Enables a global, static metrics collector
7375
static_core = ["metrics", "dep:erased_set"]

0 commit comments

Comments
 (0)