diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index eca154a..d636865 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,14 @@ on: pull_request: branches: [main] +concurrency: + # A new push to the same PR or branch supersedes the run in flight. Without + # this every push queued a *fresh* full set of jobs alongside the old ones, + # so a branch pushed five times held five complete matrices at once — on + # paid Blacksmith runners, and with nothing reclaiming the superseded work. + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + env: CARGO_TERM_COLOR: always RUST_BACKTRACE: 1 @@ -14,6 +22,12 @@ jobs: test: name: Test runs-on: blacksmith-2vcpu-ubuntu-2404 + # Capped because the GitHub default is **six hours** per job, and this + # workflow is reachable from a fork pull request. Measured over the last + # six runs the slowest job here is 4m25s, so 20 minutes is roughly 5x + # headroom while removing the runaway: a stuck or hostile job now costs + # 20 minutes of a paid runner rather than a working day of one. + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -35,6 +49,7 @@ jobs: lint: name: Lint runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -55,6 +70,7 @@ jobs: docs: name: Documentation runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -72,6 +88,7 @@ jobs: msrv: name: MSRV (1.88) runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 with: @@ -89,6 +106,7 @@ jobs: wasm: name: WASM Build runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -106,6 +124,7 @@ jobs: cli-tests: name: CLI Integration Tests runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 with: @@ -126,6 +145,7 @@ jobs: coverage: name: Coverage runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 with: @@ -154,6 +174,7 @@ jobs: swift-bridge: name: Swift Bridge runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -177,6 +198,7 @@ jobs: security: name: Security Audit runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -201,6 +223,7 @@ jobs: benchmark: name: Benchmark runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 steps: - uses: actions/checkout@v6 @@ -240,6 +263,7 @@ jobs: feature-matrix: name: Feature Matrix (${{ matrix.features || 'no features' }}) runs-on: blacksmith-2vcpu-ubuntu-2404 + timeout-minutes: 20 strategy: fail-fast: false matrix: diff --git a/Cargo.lock b/Cargo.lock index b022b15..c67ebf6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -143,9 +143,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.101" +version = "1.0.104" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f0e0fee31ef5ed1ba1316088939cea399010ed7731dba877ed44aeb407a75ea" +checksum = "330a5ed07fa54e4702c9d6c4174f74427fc0ef6e214bbd677ae50a5099946470" [[package]] name = "argon2" @@ -419,6 +419,7 @@ dependencies = [ "cfg-if", "cipher", "cpufeatures 0.3.0", + "rand_core 0.10.0", ] [[package]] @@ -650,9 +651,9 @@ dependencies = [ [[package]] name = "crossbeam-epoch" -version = "0.9.18" +version = "0.9.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +checksum = "2d6914041f254d6e9176c01941b21115dcfb7089e55135a35411081bd106ef3f" dependencies = [ "crossbeam-utils", ] @@ -1120,11 +1121,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" dependencies = [ "cfg-if", - "js-sys", "libc", "r-efi", "wasip2", - "wasm-bindgen", ] [[package]] @@ -2069,7 +2068,7 @@ dependencies = [ "bit-vec", "bitflags", "num-traits", - "rand", + "rand 0.9.2", "rand_chacha", "rand_xorshift", "regex-syntax", @@ -2106,14 +2105,15 @@ dependencies = [ [[package]] name = "quinn-proto" -version = "0.11.13" +version = "0.11.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1906b49b0c3bc04b5fe5d86a77925ae6524a19b816ae38ce1e426255f1d8a31" +checksum = "04759210543be93709136e28212294a659ef5001836ff4eab4d663e4529bba83" dependencies = [ "bytes", - "getrandom 0.3.4", + "getrandom 0.4.1", "lru-slab", - "rand", + "rand 0.10.2", + "rand_pcg", "ring", "rustc-hash", "rustls", @@ -2164,6 +2164,17 @@ dependencies = [ "rand_core 0.9.5", ] +[[package]] +name = "rand" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7f5fa3a058cd35567ef9bfa5e75732bee0f9e4c55fa90477bef2dfcdbc4be80" +dependencies = [ + "chacha20", + "getrandom 0.4.1", + "rand_core 0.10.0", +] + [[package]] name = "rand_chacha" version = "0.9.0" @@ -2198,6 +2209,15 @@ version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c8d0fd677905edcbeedbf2edb6494d676f0e98d54d5cf9bda0b061cb8fb8aba" +[[package]] +name = "rand_pcg" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "caa0f4137e1c0a72f4c651489402276c8e8e1cf081f3b0ba156d2cbeef09e86a" +dependencies = [ + "rand_core 0.10.0", +] + [[package]] name = "rand_xorshift" version = "0.4.0" diff --git a/cdx-core/src/document/tests.rs b/cdx-core/src/document/tests.rs index 3b8d214..bfc8ef1 100644 --- a/cdx-core/src/document/tests.rs +++ b/cdx-core/src/document/tests.rs @@ -224,7 +224,7 @@ fn test_extension_validation_mixed() { assert!(report.used_namespaces.contains(&"semantic".to_string())); assert!(report.used_namespaces.contains(&"forms".to_string())); assert_eq!(report.undeclared, vec!["forms"]); - assert!(report.warnings.len() == 1); + assert_eq!(report.warnings.len(), 1); } #[test]