Skip to content

ci: release builds run weekly and on their own changes, the changelog render on demand, and the nightly only what PR CI does not (C7) - #722

Merged
DrunkOnJava merged 2 commits into
mainfrom
ci/c7-trim-runs
Oct 5, 2026
Merged

DrunkOnJava merged 2 commits into
mainfrom
ci/c7-trim-runs

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Oct 5, 2026 •

Copy link
Copy Markdown
Owner

From the CI audit of 2026-10-05:

  • release-binaries ran the full five-platform LTO build 16 times in five
    days, as Cargo.lock in its pull-request paths fired it on every
    dependency bump. It runs on pull requests that touch the workflow or
    docker/, and weekly on main.
  • changelog.yml ran on every push to main (111 runs) and every tag, and
    nothing consumed either artifact (the release writes its notes with
    --generate-notes). It runs on demand; its stale notes about committing
    back to main are gone.
  • corpus-nightly keeps only what goes wider than PR CI: Tier 2 health over
    32 projects and the project corpus smoke. Its tier 3 was a subset of the
    IfcOpenShell job and its tier 4 (field-type coverage, samples, IFC
    roundtrip, bench compile) all run in PR CI.

Note

Low Risk
Workflow-only changes reduce CI cost; coverage removed from nightly is documented as already on PR CI, with weekly release-binary builds preserving matrix validation.

Overview
CI audit (C7) cuts redundant GitHub Actions runs while keeping release safety nets.

The changelog workflow no longer runs on every main push or v* tag; it is workflow_dispatch only, still uploading CHANGELOG-UNRELEASED.md or RELEASE_NOTES.md as artifacts for manual curation (release notes on GitHub already use --generate-notes).

Release binaries no longer trigger on PRs that only change Cargo.toml / Cargo.lock; PRs still run the full matrix when the workflow or docker/** changes, and a weekly Sunday cron on main exercises the five-platform LTO matrix so releases are not untested.

Corpus nightly is narrowed to what PR CI does not widen: Tier 2 health at limit 32 (vs 8 on PR) and project corpus smoke. Removed jobs/steps duplicate PR CI—tier 3 IFC export validation, tier 4 family/samples/roundtrip/bench compile, and project_count_fixtures.

Reviewed by Cursor Bugbot for commit 058c7b1. Configure here.

… render on demand, and the nightly only what PR CI does not (C7)

From the CI audit of 2026-10-05:

- release-binaries ran the full five-platform LTO build 16 times in five
  days, as Cargo.lock in its pull-request paths fired it on every
  dependency bump. It runs on pull requests that touch the workflow or
  docker/, and weekly on main.
- changelog.yml ran on every push to main (111 runs) and every tag, and
  nothing consumed either artifact (the release writes its notes with
  --generate-notes). It runs on demand; its stale notes about committing
  back to main are gone.
- corpus-nightly keeps only what goes wider than PR CI: Tier 2 health over
  32 projects and the project corpus smoke. Its tier 3 was a subset of the
  IfcOpenShell job and its tier 4 (field-type coverage, samples, IFC
  roundtrip, bench compile) all run in PR CI.
@DrunkOnJava
DrunkOnJava merged commit 8e4cc43 into main Oct 5, 2026
32 checks passed
@DrunkOnJava
DrunkOnJava deleted the ci/c7-trim-runs branch October 5, 2026 14:00
DrunkOnJava added a commit that referenced this pull request Oct 5, 2026
…nd env-config needs no download (C8) (#723)

From the CI audit of 2026-10-05. This is stacked on #722 (C7), whose
commit it includes until #722 merges.

**Before:**
- `fetch-corpus` followed the upstream HEAD of phi-ag/rvt and
magnetar-io/revit-test-datasets. Six different phi-ag commits were in
the cache.
- The nightly, perf, deploy and publish workflows checked out magnetar's
HEAD directly.
- So CI could change colour with no commit here. env-config also
downloaded Cursor's schema on every pull request.

**Now:**
- **Pins.** `fetch-corpus` pins each corpus to a commit: phi-ag
`d2eb1f3` and magnetar `fd755e1`, today's heads, so existing caches
still hit. After checkout or cache restore it checks that the tree is
that commit, and it passes its inputs through `env` (zizmor's
template-injection finding). Moving a corpus is an edit of its commit in
the action, and that pull request runs CI on the new corpus.
- **Direct checkouts.** The five direct checkouts now use the action.
publish.yml's pass `cache: false`, so the release path restores no
cache.
- **Cursor schema.** env-config validates against
`tools/ci/cursor-environment.schema.json`, a copy of the published
schema taken 2026-10-05.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Changes are limited to GitHub Actions and vendored JSON schema; they
reduce flaky external dependencies and make corpus versions explicit,
with no application runtime or auth changes.
> 
> **Overview**
> **CI determinism for external test data:** `fetch-corpus` no longer
tracks upstream `HEAD`; it resolves **fixed commits** for `phi-ag/rvt`
and `magnetar-io/revit-test-datasets`, keys the Actions cache on those
SHAs, checks out with `ref` set, and **fails if the tree is not that
commit**. A new `cache` input (default on) lets release smokes skip
cache restore/save.
> 
> **Workflow wiring:** Nightly corpus, perf budgets, viewer deploy, and
publish release smokes that used raw `actions/checkout` + LFS now go
through `fetch-corpus` so every job shares the same pin and
verification.
> 
> **Env-config lint:** `.cursor/environment.json` is validated against a
**repo copy** of Cursor’s environment schema
(`tools/ci/cursor-environment.schema.json`) instead of downloading from
`cursor.com` on each run.
> 
> The diff also carries **C7 CI cost trims** from the stacked branch:
changelog is **manual-only** (`workflow_dispatch`), corpus nightly drops
redundant tier 3/4 jobs, and `release-binaries` stops running on every
`Cargo.lock` PR while adding a **weekly main** schedule.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
fb5ea14. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
DrunkOnJava added a commit that referenced this pull request Oct 18, 2026
…e release binaries (C10) (#733)

These are the CI audit's last C10 items, plus fixes for the findings zizmor reported after #721.

**zizmor findings**
- **impostor-commit and ref-version-mismatch.**
  - dtolnay/rust-toolchain rebuilds its `stable`, `nightly` and `master` branches, so the commits we had pinned were no longer on any branch.
  - Every use is re-pinned to one commit of the action's `master` branch, `683b588` (2026-10-16), with the `toolchain` input each already passed. `master` only moves forward, so the pin cannot become an impostor commit again; `stable` had diverged from the commit pinned on 2026-10-05 by the time this landed. zizmor's `ref-version-mismatch` still warns when `master` moves on (#765 replaces the action with `rustup`).
- **artipacked.** The 32 checkouts that kept the token now set `persist-credentials: false`. No workflow pushes, and every `gh` call authenticates with `GH_TOKEN`.
- **cache-poisoning.** publish.yml no longer restores any cache, so a release is built from nothing a pull request's run could have written.

**Other C10 items**
- publish.yml gets a concurrency group with `cancel-in-progress: false`, so a second release run waits instead of racing the first.
- CI's Python packages are pinned in `tools/ci/requirements-ifc.txt` (ifcopenshell 0.8.5) and `tools/ci/requirements-test.txt` (jsonschema 4.26.0, pytest 8.4.2), and a new Dependabot `pip` entry watches them.
- IfcOpenShell 0.9 and pytest 9 are major updates, so moving to them stays the maintainer's call.
- codeql.yml now runs on `ubuntu-24.04`; C5 (#715) missed it.
- Release binaries are built with `cargo auditable` 0.7.7, so `cargo audit bin` can check a shipped binary against RustSec. There is a CHANGELOG entry for this. The release-binaries job then reads each Linux binary's section headers and fails if `.dep-v0` is gone; on this PR's run it was present in `rvt-info`, `rvt-ifc` and `rvt-analyze` on both musl targets, with `[profile.release] strip = true` unchanged.

**Testing**
- The ci.yml jobs that install from the requirements files run on this pull request.
- release-binaries runs on this pull request because its own workflow file changed (#722).
- publish.yml runs only on a tag, so its cache and concurrency changes are checked by YAML parsing and zizmor alone.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant