diff --git a/.github/workflows/coverage.yaml b/.github/workflows/coverage.yaml index fdf52eeebb2..c915f761bc4 100644 --- a/.github/workflows/coverage.yaml +++ b/.github/workflows/coverage.yaml @@ -2,16 +2,17 @@ name: Coverage on: + # Coverage is expensive (xlarge runner, 180-min cap) and non-gating (no + # floor), so it runs nightly / on-demand instead of on every PR. push:main is + # kept so the GitHub-Pages coverage trend still updates on merge. push: branches: [main] paths-ignore: - '.github/styles/**' - 'web/**' - pull_request: - branches: [main] - paths-ignore: - - '.github/styles/**' - - 'web/**' + schedule: + - cron: '0 7 * * *' # 07:00 UTC daily (off-peak) + workflow_dispatch: permissions: read-all diff --git a/.github/workflows/native-cargo.yaml b/.github/workflows/native-cargo.yaml index 2853a313975..647a0b851f5 100644 --- a/.github/workflows/native-cargo.yaml +++ b/.github/workflows/native-cargo.yaml @@ -2,16 +2,12 @@ name: Cargo Native on: - push: - branches: [main] - paths-ignore: - - '.github/styles/**' - - 'web/**' - pull_request: - branches: [main] - paths-ignore: - - '.github/styles/**' - - 'web/**' + # Cargo Native (Linux + Windows) is deferred to a nightly schedule + + # on-demand. Per-PR build/test signal is covered by the Nix (Bazel Dev) lane; + # this keeps full cargo and cross-platform coverage running daily against main. + schedule: + - cron: '0 7 * * *' # 07:00 UTC daily (off-peak) + workflow_dispatch: permissions: read-all diff --git a/.github/workflows/nix.yaml b/.github/workflows/nix.yaml index 19d5746fb63..42ffb715650 100644 --- a/.github/workflows/nix.yaml +++ b/.github/workflows/nix.yaml @@ -12,6 +12,12 @@ on: paths-ignore: - '.github/styles/**' - 'web/**' + # The Cargo Dev lane (nix-cargo) runs nightly only — see its per-job `if`. The + # other jobs here (Bazel Dev, installation, integration, RBE) stay on the + # per-PR path and are skipped on the schedule via `if: != 'schedule'`. + schedule: + - cron: '0 7 * * *' # 07:00 UTC daily (off-peak) + workflow_dispatch: permissions: read-all @@ -21,6 +27,7 @@ concurrency: jobs: nix-bazel: + if: ${{ github.event_name != 'schedule' }} strategy: fail-fast: false matrix: @@ -75,7 +82,9 @@ jobs: with: nativelink_attic_token: ${{ secrets.NATIVELINK_ATTIC_TOKEN }} + # Cargo Dev (Linux-only) moved off the per-PR critical path: nightly / on-demand only. nix-cargo: + if: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }} strategy: fail-fast: false matrix: @@ -109,6 +118,7 @@ jobs: nativelink_attic_token: ${{ secrets.NATIVELINK_ATTIC_TOKEN }} installation: + if: ${{ github.event_name != 'schedule' }} strategy: fail-fast: false matrix: @@ -139,6 +149,7 @@ jobs: nativelink_attic_token: ${{ secrets.NATIVELINK_ATTIC_TOKEN }} integration: + if: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }} name: ${{ matrix.test-name }} strategy: matrix: @@ -168,6 +179,7 @@ jobs: # rbe-toolchain is slow because it has many subcommands, so split it out generate-rbe-commands: + if: ${{ github.event_name != 'schedule' }} runs-on: ubuntu-24.04 outputs: matrix: ${{ steps.set-matrix.outputs.matrix }} @@ -188,6 +200,7 @@ jobs: id: set-matrix rbe-toolchain: + if: ${{ github.event_name != 'schedule' }} name: rbe ${{ matrix.command}} needs: [generate-rbe-commands] strategy: