Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
99062cf
ci: pin third-party actions and fail Codecov uploads closed
cursoragent Nov 10, 2026
2d94ba5
docs: record Codecov and third-party action SHA pins
cursoragent Nov 10, 2026
0742971
ci: fail the assets coverage job closed
cursoragent Nov 10, 2026
cd3f8ad
ci: lock Codecov quotes, CLI pin, and coverage permissions
cursoragent Nov 10, 2026
b21db56
ci: upload Codecov with OIDC and flatten block-scalar uses
cursoragent Nov 10, 2026
32707f6
ci: parse workflow policy checks and split Codecov upload jobs
cursoragent Nov 10, 2026
7ffdbf8
Merge remote-tracking branch 'origin/main' into cursor/pin-codecov-ac…
cursoragent Nov 10, 2026
6b076b1
ci: parse codecov policy from YAML and pin artifact actions
cursoragent Nov 10, 2026
a837dbe
Pin coverage HTML artifact upload and extend codecov workflow policy …
cursoragent Nov 10, 2026
e6e5c66
docs: align CI artifact pin wording with workflow policy
cursoragent Nov 10, 2026
66a0c44
ci: close codecov workflow policy gaps
cursoragent Nov 10, 2026
281e231
ci: lock codecov upload edges and kani args
cursoragent Nov 10, 2026
d252603
ci: lock coverage job end, kani inputs, and checkout credentials
cursoragent Nov 10, 2026
7b7fe92
docs: cite the pinned kani action and the coverage job end
cursoragent Nov 10, 2026
d923f01
ci: pin kani command and working-directory
cursoragent Nov 10, 2026
d299652
docs: name coverage workflows on checkout persist-credentials rule
cursoragent Nov 10, 2026
d202993
ci: pin the coverage producer job key set
cursoragent Nov 10, 2026
590b047
docs: cite the rust-ci-setup toolchain commit
cursoragent Nov 10, 2026
1329f24
ci: lock the tarpaulin script and pin kani actions
cursoragent Nov 10, 2026
be6ee82
docs: record the tarpaulin script and kani checkout rule
cursoragent Nov 10, 2026
8bc112c
ci: match locked workflow steps to their canonical form
cursoragent Nov 10, 2026
964265b
docs: state the exact step rule and correct the ui cites
cursoragent Nov 10, 2026
25df619
ci: lock coverage, editor, and Kani jobs to canonical step lists
cursoragent Nov 10, 2026
b4c36c5
ci: lock Kani job shape, the summary gate, and report uploads
cursoragent Nov 10, 2026
6748532
ci: lock summary job shape and report publish names
cursoragent Nov 10, 2026
530ee5e
ci: lock local action shapes and reusable workflow uses
cursoragent Nov 11, 2026
10a7ddd
ci: fail closed on coverage upload names and local uses
cursoragent Nov 11, 2026
3788edd
ci: reject non-printable upload names and dead expression scans
cursoragent Nov 11, 2026
c0121c4
ci: pin the upload-name range and exact editor test permissions
cursoragent Nov 11, 2026
156ee73
ci: pin permission spelling messages and the publish-path name check
cursoragent Nov 11, 2026
6d9b1fa
ci: pin repeated permission keys and the publish-path name check
cursoragent Nov 11, 2026
3d3a490
ci: pin the middle of an upload name and repeated workflow keys
cursoragent Nov 11, 2026
fdb41cd
docs: correct the sun-position and heightmap mutant notes
cursoragent Nov 11, 2026
d1914ad
ci: reject a repeated mapping key and pin the workflow loader
cursoragent Nov 11, 2026
00b91a7
terrain: reject a heightmap resolution above 32769
cursoragent Nov 11, 2026
151289c
ci: match trigger-key spellings and lock workflow key sets
cursoragent Nov 17, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
ci: parse codecov policy from YAML and pin artifact actions
Read continue-on-error, Kani, and cargo-llvm-cov from parsed YAML.
Limit the upload job to an exact key set, download inputs, and
permissions. SHA-pin the four new artifact actions.

Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
  • Loading branch information
cursoragent and lazyxeon committed Nov 10, 2026
commit 6b076b15c00f7a2ce7f8180290095c49143c9400
5 changes: 2 additions & 3 deletions .github/workflows/aw-editor-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ jobs:
cargo llvm-cov --package aw_editor --lib --lcov --output-path lcov.info

- name: Upload coverage report
uses: actions/upload-artifact@v7
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
name: aw-editor-lcov
path: lcov.info
Expand All @@ -140,14 +140,13 @@ jobs:
name: Codecov upload
needs: coverage
Comment thread
cursor[bot] marked this conversation as resolved.
Resolved
permissions:
actions: read
contents: read
id-token: write
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Download coverage report
uses: actions/download-artifact@v8
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with:
name: aw-editor-lcov
path: .
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
cargo tarpaulin --out Xml --output-dir coverage --exclude-files 'src/main.rs' --exclude-files 'tests/*'

- name: Upload coverage XML
uses: actions/upload-artifact@v7
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
with:
name: coverage-xml
path: tools/astraweave-assets/coverage/cobertura.xml
Expand Down Expand Up @@ -82,15 +82,14 @@ jobs:
name: Codecov upload
needs: coverage
Comment thread
cursor[bot] marked this conversation as resolved.
Resolved
permissions:
actions: read
contents: read
id-token: write
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- name: Download coverage XML
uses: actions/download-artifact@v8
uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
with:
name: coverage-xml
path: tools/astraweave-assets/coverage
Expand Down
4 changes: 2 additions & 2 deletions docs/current/CI_ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ These path-filtered workflows are not in the required set because a filter would
| Full 3-OS `cargo nextest` plus a release build of the core crates, and demo validation | `ci.yml` on push, schedule 04:30 UTC, dispatch. Not on pull requests. |
| 5-toolchain matrix (stable, 1.89.0, 1.88.0, beta, pinned nightly) | `toolchain-management.yml` on push to main, schedule 05:40 UTC, dispatch. The nightly matrix label is `pinned-nightly`. The channel is the date in `.github/rust-nightly-channel` (#560). Miri, sanitizers, and fuzz use that same pin. The checkout sets `lfs: true` (#348) so `ASSET_MANIFEST.tsv` hashes the Aravath blobs, not the pointer files. `Toolchain Validation (1.89.0)` runs workspace clippy `-D warnings`, with that workflow's package excludes. #360 closed the `expect` on schedule registration. #358 is closed. The fix is #360. That 1.89.0 clippy step is expected green. The CI agent is confirming it on main. #375 removes the 50 ms debug wall-clock assert from `view_ring_lod_keeps_the_forest_under_budget`. The test still requires `total > 400` and `kept < 900`. macOS 1.89 on run 39084152246 measured 50.776916 ms, failed `as_millis() < 50`, and skipped `Run clippy with toolchain`. That host-clock assert no longer skips clippy. MSRV stays on the pull request. |
| Sanitizers | `sanitizers.yml` on push and schedule 03:00 UTC. Not on pull requests. |
| Coverage | `coverage.yml` on push to main, schedule 06:10 UTC, dispatch. Its Codecov step and the `aw-editor-tests.yml` coverage upload use `codecov/codecov-action` commit `303a32d7a59b442fa8d48b6a1cc6825c09c847a5` (# v7.1.1), CLI `version: v11.3.2`, `fail_ci_if_error: true`, `disable_search: true`, an explicit `files:` path, and `use_oidc: true`. Neither workflow sets a `token` input, a `CODECOV_TOKEN` key, or a `secrets.` reference. Generation stays `contents: read` and uploads the report as an artifact. A separate job downloads that artifact. Its steps are `actions/download-artifact` and the pinned Codecov action. That job sets `actions: read`, `contents: read`, and `id-token: write`. Top-level `permissions` stay `{}`. Neither workflow runs on pull requests. The generation job and the upload job do not set `continue-on-error`. The editor coverage job installs `cargo-llvm-cov` `0.9.1` with `--locked`. `editor-ci.yml` installs that same version with `tool: cargo-llvm-cov@0.9.1` on `taiki-e/install-action` commit `3f7c3597aa4e6da3f315e128de702ce61e7b2877`. `editor-ci.yml` and `kani.yml` set top-level `permissions: {}` and `contents: read` on every job. Kani steps pass `kani-version: 0.68.0`. The Kani `timeout` input is `type: number` with default `300`. Each Kani job allowlists 60, 120, 300, 600, and 900, then passes that result in `args`. |
| Coverage | `coverage.yml` on push to main, schedule 06:10 UTC, dispatch. Its Codecov step and the `aw-editor-tests.yml` coverage upload use `codecov/codecov-action` commit `303a32d7a59b442fa8d48b6a1cc6825c09c847a5` (# v7.1.1), CLI `version: v11.3.2`, `fail_ci_if_error: true`, `disable_search: true`, an explicit `files:` path, and `use_oidc: true`. Neither workflow sets a `token` or `CODECOV_TOKEN` key, and neither puts a `secrets` context in the Codecov step, that job's `env`, or the workflow `env`. Generation stays `contents: read` and uploads the report as an artifact. The coverage XML upload and the editor report upload use `actions/upload-artifact` commit `cf430e030ddbb5b0abf93d22962f4752f3646cd9` (# v7.0.2). A separate job downloads that artifact with `actions/download-artifact` commit `9000827ccba6bdab643e8b6fd33ac0654aef8333` (# v8.0.2). `with:` on that download is `name` and `path`. That job's permissions are exactly `contents: read` and `id-token: write`. Top-level `permissions` stay `{}`. Neither workflow runs on pull requests. The generation job and the upload job do not set `continue-on-error`. The editor coverage job installs `cargo-llvm-cov` `0.9.1` with `--locked`. `editor-ci.yml` installs that same version with `tool: cargo-llvm-cov@0.9.1` on `taiki-e/install-action` commit `3f7c3597aa4e6da3f315e128de702ce61e7b2877`. `editor-ci.yml` and `kani.yml` set top-level `permissions: {}` and `contents: read` on every job. Kani steps pass `kani-version: 0.68.0`. The Kani `timeout` input is `type: number` with default `300`. Each Kani job allowlists 60, 120, 300, 600, and 900, then passes that result in `args`. |
| CodeQL | push to main and weekly (Sunday 03:00 UTC). Not on pull requests. |
| Benchmarks, including `aw_build` | see item 1 above. Shard count is 16 (`shard_index` 0–15, `--shard-count 16`). Shards 13, 14, and 15 are `astraweave-render@a`, `@b`, and `@c` (explicit thirds of that crate's bench targets). #374 flat-samples `fluid_baseline_50k` and is on main. Shard 0 is `astraweave-net`, `astraweave-profiling`, `astraweave-water`, and `astraweave-localsim` (#351). Each sharded bench target gets `timeout 600` after `cargo bench --no-run`. Compilation is outside that limit. The `aw_build` job is separate and uses its 30-minute job timeout. The aggregate expects 53 package records. `github-action-benchmark` stores `dev/bench` on branch `benchmark-data`. `gh-pages` is the docs site, and main also has a `gh-pages/` directory, so the old checkout never published that history. The PR comment step clones `github.com/<owner>/<repo>`, does not auto-push, and comments only when a result exceeds the alert threshold. |
| Integration tests other than the replay hash | `integration-tests.yml` on push and schedule 04:00 UTC. |
Expand Down Expand Up @@ -101,7 +101,7 @@ When the same tests also run under nextest (an affected crate on a pull request,

Those four workflows still trigger on every pull request. The heavy jobs are conditional. A skipped job reports success to branch protection. `on.paths` is not used: a path filter would leave a required check pending. `determinism-replay.yml` has no scope and no path filter. The Aravath golden-hash matrix still expands when the scope is cold, so the three `Replay hash (...)` check names are created; the compile steps are skipped. `net-tests.yml` no longer uses `paths-ignore` for markdown. A docs-only pull request classifies `run=false` and skips the `net-tests` job by condition instead of omitting the workflow. Push, schedule, and `workflow_dispatch` do not consult the diff.

`scripts/ci/test_affected_crates.py` and `scripts/ci/test_workflow_policy.py` lock this in. `actionlint` 1.7.12 reports two findings on the workflow files, both the pre-existing `gpu` runner label in `allocation-measurement.yml` and `gpu-frame-budget.yml`. Those two findings are the same on the base commit. The policy test parses each file with `yaml.safe_load` and checks every `uses` value, including `jobs.*.steps[*].uses`, `jobs.*.uses`, and composite `runs.steps[*].uses`. Quotes, block scalars (`>`, `>-`, `|`, `|-`, and an explicit indent such as `>2-`), flow mappings, aliases, and an escaped `@` are the parsed string. A local `./` action has no ref. `docker://` must end in `@sha256:` and 64 hex digits. The five pinned `actions/*` names stay on the major-tag rule. Every other ref, including any other `actions/*` name, must be a 40-character commit SHA. Invalid YAML fails the check. Every `codecov/codecov-action` step must set `fail_ci_if_error` to true, `version` to an exact `vX.Y.Z`, `disable_search` to true, `files` to a non-empty path, and `use_oidc` to true. Those five keys are read only from that step's `with:` mapping. The same key on the step or under `env:` fails the check. A `token` key, a `CODECOV_TOKEN` key, and any `secrets.` reference in the step fail the check. A job that runs the action, and a job named in that job's `needs:`, must not set `continue-on-error`. The action is allowed only in a job whose steps are `actions/checkout` or `actions/download-artifact` plus the SHA-pinned Codecov action, and that job must set `id-token: write`. On `coverage.yml` and `aw-editor-tests.yml`, parsed top-level `permissions` must be `{}`, and a missing top-level `permissions` key fails the check. The check rejects a `write-all` scalar or value, and a permission value `write`, including a flow mapping or a quoted key, except `id-token: write` on that upload job. `kani.yml` and `editor-ci.yml` must set top-level `permissions` to `{}` and each job's `permissions` to exactly `contents: read`. The Kani `timeout` input must be `type: number` with default `300`. Each of the four Kani jobs allowlists 60, 120, 300, 600, and 900 and passes `steps.timeout.outputs.value` in `args`. Those `args` lines do not read `github.event.inputs`. Every Kani step must set `kani-version` to an exact `X.Y.Z`. A `uses:` ref of `@stable` fails the SHA rule. `cargo install cargo-llvm-cov` must pass `--version X.Y.Z` and `--locked`, and an `install-action` step that installs it must set `tool: cargo-llvm-cov@X.Y.Z`.
`scripts/ci/test_affected_crates.py` and `scripts/ci/test_workflow_policy.py` lock this in. `actionlint` 1.7.12 reports two findings on the workflow files, both the pre-existing `gpu` runner label in `allocation-measurement.yml` and `gpu-frame-budget.yml`. Those two findings are the same on the base commit. The policy test parses each file with `yaml.safe_load` and checks every `uses` value, including `jobs.*.steps[*].uses`, `jobs.*.uses`, and composite `runs.steps[*].uses`. Quotes, block scalars (`>`, `>-`, `|`, `|-`, and an explicit indent such as `>2-`), flow mappings, aliases, and an escaped `@` are the parsed string. A local `./` action has no ref. `docker://` must end in `@sha256:` and 64 hex digits. The five pinned `actions/*` names stay on the major-tag rule. The coverage XML upload, the editor report upload, and both Codecov download steps are commit-pinned anyway: `actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9` (# v7.0.2) and `actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333` (# v8.0.2). `git ls-remote` shows the `v7` and `v8` tags on those same commits. Every other ref, including any other `actions/*` name, must be a 40-character commit SHA. Invalid YAML fails the check. Every `codecov/codecov-action` step, matched case-insensitively, must set `fail_ci_if_error`, `disable_search`, and `use_oidc` to a value the runner passes as the string `true`: a plain scalar `true`, `True`, or `TRUE`, or the quoted string `true`. `yes` and `on` fail that check. `version` must be an exact `vX.Y.Z` and `files` a non-empty path. Those keys are read only from that step's `with:` mapping, compared case-insensitively. The same key on the step or under `env:` fails the check. The `with:` keys must be among `files`, `disable_search`, `flags`, `name`, `version`, `fail_ci_if_error`, and `use_oidc`. A `token` or `CODECOV_TOKEN` key, compared case-insensitively, fails the check on the step, in that job's `env`, and in the workflow `env`. A `secrets` context inside `${{ }}` in those same places fails the check, including `secrets['NAME']` and `SECRETS.NAME`. The secret name is not special-cased. A job that runs the action, and a job named in that job's `needs:`, must not set `continue-on-error` to a runner-true value on the parsed job or on any parsed step. A quoted key and a flow mapping count. On `coverage.yml` and `aw-editor-tests.yml` only, the action is allowed only in a job whose keys are exactly `name`, `needs`, `permissions`, `runs-on`, `timeout-minutes`, and `steps`, and whose steps are `actions/download-artifact` plus the SHA-pinned Codecov action. That download's `with:` keys are only `name` and `path`. `container:`, `services:`, `uses:`, and a checkout step fail the check. That job's permissions must be exactly `contents: read` and `id-token: write`. Parsed top-level `permissions` must be `{}`, and a missing top-level `permissions` key fails the check. The check rejects a `write-all` scalar or value, and a permission value `write`, including a flow mapping or a quoted key. `on:` is parsed as a string, a list, or a mapping, and a bare `on` key loads as `True`. Those two workflows may list only `push`, `schedule`, and `workflow_dispatch`. `pull_request`, `pull_request_target`, `workflow_run`, and `issue_comment` fail the check. `kani.yml` and `editor-ci.yml` must set top-level `permissions` to `{}` and each job's `permissions` to exactly `contents: read`. The Kani `timeout` input must be `type: number` with default `300`. Each of the four Kani jobs allowlists 60, 120, 300, 600, and 900 and passes `steps.timeout.outputs.value` in `args`. Those `args` lines do not read `github.event.inputs`. Every Kani step must set `kani-version` to an exact `X.Y.Z` under `with:` only. The same key on the step or under `env:` fails the check. A `uses:` ref of `@stable` fails the SHA rule. Every `cargo install` of `cargo-llvm-cov` in a run script must pass `--version X.Y.Z` and `--locked`, including a second install after `&&` and a backslash continuation. An `install-action` step that installs it must set `tool: cargo-llvm-cov@X.Y.Z` under `with:` only.

## Cache

Expand Down
Loading
Loading