[marshal] Remove Parent by Digest #22006
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Slow | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| merge_group: | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: tests-slow-${{ github.head_ref || github.ref_name || github.run_id }} | |
| cancel-in-progress: ${{ github.event_name == 'pull_request' }} | |
| env: | |
| CARGO_TERM_COLOR: always | |
| FUZZ_VERSION: 0.12.0 | |
| NIGHTLY_VERSION: nightly | |
| jobs: | |
| Tests: | |
| name: "Tests (os: ${{ matrix.os }}, flags: \"${{ matrix.flags }}\") (partition: ${{ matrix.partition }}/8)" | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 180 | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, windows-latest, macos-latest] | |
| partition: [1, 2, 3, 4, 5, 6, 7, 8] | |
| flags: | |
| - "--features commonware-runtime/iouring-storage" | |
| - "--features commonware-runtime/iouring-network" | |
| - "--no-default-features" | |
| - "" | |
| exclude: | |
| # Only run io_uring features on Ubuntu | |
| - os: windows-latest | |
| flags: "--features commonware-runtime/iouring-storage" | |
| - os: macos-latest | |
| flags: "--features commonware-runtime/iouring-storage" | |
| - os: windows-latest | |
| flags: "--features commonware-runtime/iouring-network" | |
| - os: macos-latest | |
| flags: "--features commonware-runtime/iouring-network" | |
| # Only run --no-default-features on Ubuntu | |
| - os: windows-latest | |
| flags: "--no-default-features" | |
| - os: macos-latest | |
| flags: "--no-default-features" | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4 | |
| - name: Clear disk space | |
| uses: ./.github/actions/disk | |
| - name: Run setup | |
| uses: ./.github/actions/setup | |
| with: | |
| additional-cache-key: ${{ matrix.flags || 'default' }}-part-${{ matrix.partition }} | |
| - name: Install just & nextest | |
| uses: taiki-e/install-action@0c5db7f7f897c03b771660e91d065338615679f4 # v2.60.0 | |
| with: | |
| tool: just@1.43.0,cargo-nextest@0.9.133 | |
| - name: Run slow tests | |
| run: just test ${{ matrix.flags }} --partition hash:${{matrix.partition}}/8 --verbose --profile slow | |
| Tests-Gate: | |
| name: "Slow-Tests" | |
| runs-on: ubuntu-latest | |
| needs: Tests | |
| if: always() | |
| steps: | |
| - name: Check test results | |
| run: | | |
| if [ "${{ needs.Tests.result }}" != "success" ]; then | |
| echo "Tests failed or were cancelled" | |
| exit 1 | |
| fi | |
| echo "All tests passed successfully!" | |
| Benchmarks: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| include: | |
| - package: commonware-cryptography | |
| test_flags: "" | |
| lint_flags: "" | |
| - package: commonware-storage | |
| test_flags: "--features test-traits" | |
| lint_flags: "--cfg full_bench" | |
| - package: commonware-storage | |
| test_flags: "--features commonware-runtime/iouring-storage,test-traits" | |
| lint_flags: "--cfg full_bench" | |
| - package: commonware-coding | |
| test_flags: "" | |
| lint_flags: "" | |
| - package: commonware-math | |
| test_flags: "" | |
| lint_flags: "" | |
| - package: commonware-utils | |
| test_flags: "" | |
| lint_flags: "" | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4 | |
| - name: Run setup | |
| uses: ./.github/actions/setup | |
| - name: Install just | |
| uses: taiki-e/install-action@0c5db7f7f897c03b771660e91d065338615679f4 # v2.60.0 | |
| with: | |
| tool: just@1.43.0 | |
| - name: Test benchmarks | |
| run: just test-benches ${{ matrix.package }} '${{ matrix.test_flags }}' '${{ matrix.lint_flags }}' | |
| Fuzz: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 180 | |
| strategy: | |
| matrix: | |
| fuzz_dir: [broadcast/fuzz, codec/fuzz, coding/fuzz, collector/fuzz, consensus/fuzz, cryptography/fuzz, math/fuzz, p2p/fuzz, runtime/fuzz, storage/fuzz, stream/fuzz, utils/fuzz] | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4 | |
| - name: Clear disk space | |
| uses: ./.github/actions/disk | |
| - name: Run setup | |
| uses: ./.github/actions/setup | |
| with: | |
| additional-toolchain: ${{ env.NIGHTLY_VERSION }} | |
| - name: Get Rust version | |
| id: rust-version | |
| run: echo "rust_version=$(rustc +${{ env.NIGHTLY_VERSION }} --version)" >> "$GITHUB_OUTPUT" | |
| - name: Cache cargo-fuzz | |
| id: cargo-fuzz-cache | |
| uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4 | |
| with: | |
| path: ${{ env.CARGO_HOME || '~/.cargo' }}/bin/cargo-fuzz | |
| key: ${{ runner.os }}-${{ env.FUZZ_VERSION }}-cargo-fuzz-${{ steps.rust-version.outputs.rust_version }} | |
| - name: Install cargo-fuzz | |
| if: steps.cargo-fuzz-cache.outputs.cache-hit != 'true' | |
| run: cargo +${{ env.NIGHTLY_VERSION }} install cargo-fuzz --version ${{ env.FUZZ_VERSION }} | |
| - name: Install just | |
| uses: taiki-e/install-action@0c5db7f7f897c03b771660e91d065338615679f4 # v2.60.0 | |
| with: | |
| tool: just@1.43.0 | |
| - name: Ensure corpus directory exists | |
| run: mkdir -p ${{ matrix.fuzz_dir }}/corpus | |
| - name: Compute fuzz corpus cache key prefix | |
| id: fuzz-corpus-cache-key | |
| run: | | |
| sanitized_fuzz_dir="$(echo "${{ matrix.fuzz_dir }}" | tr '/' '-')" | |
| echo "prefix=${{ runner.os }}-fuzz-corpus-${sanitized_fuzz_dir}" >> "$GITHUB_OUTPUT" | |
| - name: Restore fuzz corpus | |
| id: fuzz-corpus-restore | |
| uses: actions/cache/restore@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4 | |
| with: | |
| path: ${{ matrix.fuzz_dir }}/corpus | |
| key: ${{ steps.fuzz-corpus-cache-key.outputs.prefix }}-${{ github.run_id }}-${{ github.run_attempt }} | |
| restore-keys: | | |
| ${{ steps.fuzz-corpus-cache-key.outputs.prefix }}- | |
| - name: Test all targets | |
| run: just fuzz ${{ matrix.fuzz_dir }} 60 | |
| - name: Save fuzz corpus | |
| if: success() && github.ref == 'refs/heads/main' | |
| uses: actions/cache/save@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4 | |
| with: | |
| path: ${{ matrix.fuzz_dir }}/corpus | |
| key: ${{ steps.fuzz-corpus-restore.outputs.cache-primary-key }} | |
| Unsafe: | |
| name: "Miri Tests (partition: ${{ matrix.partition }}/8)" | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 120 | |
| strategy: | |
| matrix: | |
| partition: [1, 2, 3, 4, 5, 6, 7, 8] | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4 | |
| - name: Run setup | |
| uses: ./.github/actions/setup | |
| with: | |
| toolchain: ${{ env.NIGHTLY_VERSION }} | |
| components: miri | |
| additional-cache-key: part-${{ matrix.partition }} | |
| - name: Install miri | |
| run: cargo miri setup | |
| - name: Install just & nextest | |
| uses: taiki-e/install-action@0c5db7f7f897c03b771660e91d065338615679f4 # v2.60.0 | |
| with: | |
| tool: just@1.43.0,cargo-nextest@0.9.133 | |
| - name: Run miri tests for storage::index | |
| run: | | |
| cd storage | |
| just miri index::tests --partition hash:${{matrix.partition}}/8 | |
| - name: Run miri tests for runtime::iobuf | |
| run: | | |
| cd runtime | |
| just miri iobuf:: --partition hash:${{matrix.partition}}/8 | |
| - name: Run miri tests for runtime::buffer::paged::append | |
| run: | | |
| cd runtime | |
| just miri utils::buffer::paged::append::tests:: --partition hash:${{matrix.partition}}/8 | |
| Unsafe-Tests-Gate: | |
| name: "Unsafe-Tests" | |
| runs-on: ubuntu-latest | |
| needs: Unsafe | |
| if: always() | |
| steps: | |
| - name: Check test results | |
| run: | | |
| if [ "${{ needs.Unsafe.result }}" != "success" ]; then | |
| echo "Tests failed or were cancelled" | |
| exit 1 | |
| fi | |
| echo "All tests passed successfully!" | |
| conformance: | |
| # Run conformance tests on multiple architectures to catch platform-specific | |
| # encoding differences. | |
| name: "Breaking Changes (${{ matrix.name }}) (partition: ${{ matrix.partition }}/8)" | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 90 | |
| strategy: | |
| matrix: | |
| name: [x86_64, arm64] | |
| partition: [1, 2, 3, 4, 5, 6, 7, 8] | |
| include: | |
| - name: x86_64 | |
| os: ubuntu-latest | |
| - name: arm64 | |
| os: macos-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@08eba0b27e820071cde6df949e0beb9ba4906955 # v4 | |
| - name: Run setup | |
| uses: ./.github/actions/setup | |
| with: | |
| additional-cache-key: ${{ matrix.name }}-part-${{ matrix.partition }} | |
| - name: Install just | |
| uses: taiki-e/install-action@0c5db7f7f897c03b771660e91d065338615679f4 # v2.60.0 | |
| with: | |
| tool: just@1.43.0,cargo-nextest@0.9.133 | |
| - name: Run conformance tests | |
| run: just test-conformance --partition hash:${{ matrix.partition }}/8 && git diff --exit-code | |
| Conformance-Gate: | |
| name: "Breaking Changes" | |
| runs-on: ubuntu-latest | |
| needs: conformance | |
| if: always() | |
| steps: | |
| - name: Check conformance results | |
| run: | | |
| if [ "${{ needs.conformance.result }}" != "success" ]; then | |
| echo "Conformance tests failed or were cancelled" | |
| exit 1 | |
| fi | |
| echo "All conformance tests passed successfully!" |