Skip to content

ci: Cook cache layers rarely help: macOS/Windows layers missing, evicted at the 10 GB limit, test builds recompile dependencies #2661

Open

Description

@vpacher

What

After #2604 (fix for #2603), soldr cook runs again in every lane. But in the 30 PRs merged on 2026-10-27 between 11:30 and 16:00 UTC, the cook layers removed little of the dependency compile:

  • macOS lanes MISS in almost every run. There is no macOS cook layer in the repository cache now.
  • Windows lanes HIT in 5 of 12 lane runs.
  • The Linux Fast Gate layer was evicted and saved again (14:55 UTC). Fast Gate runs between those times MISS.
  • Fast Gate compiles 111 to 147 external crates on a HIT (166 to 230 on a MISS).

Data: per lane, the cook-cache-base HIT|MISS line of the job log and the number of Compiling <crate> vX lines for crates outside the workspace.

Lane Cook key (profile) HIT / MISS External crates compiled
Fast Gate f9e7e4902-…-xlinux-host-v1 (--release) 7 / 9 HIT 111–147, MISS 166–230
Rust Cross Lint f1c7475cf-…-xlinux-host-v1 (--profile dev) 10 / 1 0–79
Rust Tier 2 Linux (build) f9e7e4902-…-xlinux-container-v1 (--release) 17 / 1 0–27
Rust Tests macOS macos-arm64-…-f1c7475cf (--profile dev) 0 / 6 67–103
Rust Tier 2 macOS macos-arm64-…-f9e7e4902 (--release) 1 / 3 78–126
Rust Tests Windows windows-x64-msvc-…-f1c7475cf (--profile dev) 2 / 4 HIT 3, MISS 57
Rust Tier 2 Windows windows-x64-msvc-…-f9e7e4902 (--release) 3 / 3 90

Example runs (PR / merge queue): #2628 40513668560 / 40516965606, #2643 40523842267 / 40529701340, #2613 40501643991 / 40504662840.

Causes

1. Only master push runs save layers, and they often skip the macOS and Windows lanes

save-cache is github.ref == 'refs/heads/master'. A master push runs only the lanes that its scope selects. Most master pushes change only CI files or Linux code, so they do not run the macOS and Windows Rust lanes, and do not save their layers. One macOS --release layer existed (HIT in the #2643 queue run 40529701340), but it is not in the cache now.

2. The repository cache is full

The cache is at the 10 GB limit: the usage API reported 9.0 to 9.9 GB today, and the entry list adds up to 10.2 GB (45 entries) at 16:30 UTC. GitHub evicts the least recently used entries. Use by key prefix (entry list, 16:10 UTC):

Prefix Size Entries
flatpak-builder 2106 MB 1
cook-base 1967 MB 5
zccache-* (tier2, ubuntu, sanitize) 2654 MB 3
qt-ccache 501 MB 1
other (apt, toolchains, setup, …) about 1.4 GB 27

Each platform needs two cook layers: one for --profile dev and one for --release (the key hash f1c7475cf and f9e7e4902). Linux has three (host release, host dev, container release). Complete macOS and Windows layers add at least 2 more GB. With the cache already full, more layers cause more evictions, and layers that are evicted cause more MISS.

3. Test builds do not use the cooked dependencies (probable)

The Fast Gate cook uses --release (when core is true, as on every master push). The Fast Gate tests build the test profile. soldr also writes in every test invocation:

soldr: warning: Cargo profile.test.debug is unspecified for <workspace>; setting CARGO_PROFILE_TEST_DEBUG=false for this invocation.

The dev profile keeps its default debug. So the test profile differs from both dev and release, and cargo test compiles the external crates again. In the master Fast Gate log 40531318146, the cook layer was a HIT (exact=true), and the lint lane still compiled 83 external crates and the rust-test lane 66. I did not confirm this cause in soldr.

Effect

The dependency compile is small compared to the tests (Fast Gate unit tests 4 to 8 min, Rust Tests Windows 11 min on a HIT). A full HIT saves about 1 to 3 min per lane. The macOS and Windows lanes are on the critical path of a full-scope PR (they start after Fast Gate), so their compile time adds directly to the merge time.

Options

# Change Effect Cost
A Save the macOS and Windows layers when they are missing: a cook-only job per platform on master pushes that change Cargo.lock or a Cargo.toml, or on a schedule macOS/Windows lanes HIT Runner minutes for each cook-only job
B Fewer cook layers: one profile per platform where the consumers allow it (for example cook only dev for the test lanes, and let the release consumers compile, or the reverse) Less cache space, fewer evictions Some lanes do not get a HIT
C Make the test profile match the cooked profile: set [profile.test] debug explicitly to the dev value, or cook the profile that the tests build Fast Gate and Rust Tests HIT for the test build Need to confirm cause 3 first
D Make room: trim the large non-cook entries (Flatpak 2.1 GB, three zccache variants 2.7 GB), or raise the repository cache limit above 10 GB Fewer evictions D2 costs money (storage above 10 GB is billed); org decision

Proposal: C first (small, measurable in one run), then A, then B and D together, so that the cache budget includes the new layers.

Related

Activity

  1. zackees commented on Oct 27, 2026

    @zackees
    Member

    /investigate

    Triage: not Ready yet — good evidence, but no claimable unit and no acceptance criterion.

    What is measurable here is already in the report (lane / key / HIT-MISS / external crates), and I could not find a duplicate: #2603 was the cook failing (fixed by #2604), #2593 is queue time, #1801 is cache capacity. Please keep this one open.

    What blocks it:

    1. The fixes are not in this repo's tracked files. The cook cache key, the save-cache policy and the cook-cache-base step live in the shared action this repo pins (.github/workflows/build-project.yaml calls zackees/ci.yml@a1917ce), and the test-profile behaviour is soldr's; the capacity question is fix(ci): reconcile global cache capacity and retain measured warm seeds #1801 (open, maintainer handed it off). So the first thing the issue needs is one line per cause saying which repo carries it — an obs-studio PR can only change the call sites and the workflow inputs.

    2. Cause 3 is stated as probable and can be settled in one command. You are right that the profiles differ by construction: the key text already carries the profile (--release f9e7e4902-… vs --profile dev f1c7475cf-…), so a --release cook layer can never serve a test build, and soldr's own soldr: warning: Cargo profile.test.debug is unspecified … setting CARGO_PROFILE_TEST_DEBUG=false makes test a third profile rather than inheriting dev. Confirming it takes one run: the same job with soldr cook --profile test (or with CARGO_PROFILE_TEST_DEBUG unset), then compare the Compiling <crate> count. Say whether the answer means "cook a test layer" or "stop selling the test profile as distinct" — those are different fixes in different repos.

    3. No acceptance criterion. "A full HIT saves about 1 to 3 min" is the effect, not the gate. Something measurable from a job log, for example: on a master-tip push that touches rust/, every Rust lane prints cook-cache-base HIT and compiles at most 10 external crates, and a macOS --release layer and a Windows --release layer both exist in the cache at that moment. That is checkable from the runs you already cite, so it stays testable without a new harness.

    4. Two of the three causes are a decision, not a defect. Saving from PR runs (save-cache: ${{ github.ref == 'refs/heads/master' }} → also on PRs) trades cache writes and evictions against the misses you measured, and the capacity question is fix(ci): reconcile global cache capacity and retain measured warm seeds #1801's. If you want that call made for you, post it as Decision needed: naming the trade-off; until then it is not something a worker should pick unilaterally.

    5. Split it when you have 2 and 3: the capacity/eviction part belongs to fix(ci): reconcile global cache capacity and retain measured warm seeds #1801, the macOS/Windows layer saving is the decision in 4, and the test-profile part is the one candidate for a normal PR (in whichever repo 2 names). Then a P0–P3 and a size: label, and it is Ready.

  2. added
    needs-investigation
    on Oct 27, 2026
  3. vpacher commented on Oct 27, 2026

    @vpacher
    MemberAuthor

    Thanks. Answers to points 1 to 5, with a measurement for cause 3.

    Cause 3: measured, and the cause is not the test profile

    Setup: a local Linux x86_64 host, soldr 0.9.43 (the version CI pins), master 637558458. For each case: delete target/, run the cook, then run the Fast Gate test compile (soldr cargo test --workspace --locked --no-run). Count the Compiling <crate> vX lines for crates outside the workspace.

    Case External crates compiled by the cook External crates compiled again by the test build
    A. soldr cook --profile dev (CI for PRs today) 48 55
    B. soldr cook --profile test 0 55 (the same crates as A)
    C. soldr cook --profile dev -- --tests fails: proptest without std (64 × E0432) 23
    D. as C, plus explicit features in the member manifests (below) 53 1 (foldhash)

    Results:

    1. dev and test do not differ in practice. soldr also sets CARGO_PROFILE_DEV_DEBUG=false for the cook (soldr: warning: Cargo profile.dev.debug is unspecified … setting CARGO_PROFILE_DEV_DEBUG=false). Case B gives the same 55 crates as case A. A separate test layer does not help.
    2. 48 of the 55 crates are dev-dependencies. The cook does not build them (proptest, criterion, rand*, regex*, tempfile, rusty-fork, …).
    3. 7 of the 55 crates were cooked, but with a different feature set (serde, serde_core, serde_json, base64, sha2, memchr, foldhash).
    4. -- --tests (cargo-chef) adds the dev-dependencies, but the cook then fails. The root [workspace.dependencies] declares proptest, base64, memchr and sha2 with default-features = false. 10 member manifests turn the defaults on again with { workspace = true, default-features = true }. Cargo honours this override, but the cargo-chef recipe does not. This is the same defect as ci: soldr cook fails since #2061, so every Rust lane compiles all dependencies #2603 (serde_json, fixed in build: Name serde_json's std feature so soldr cook builds again (#2603) #2604).
    5. With explicit features, the test build compiles 1 external crate instead of 55 (case D). The change is the build: Name serde_json's std feature so soldr cook builds again (#2603) #2604 pattern: proptest = { workspace = true, features = ["std", "fork", "timeout", "bit-set"] }, base64 = { …, features = ["std", "simd-unsafe"] }, memchr = { …, features = ["std"] }, sha2 = { …, features = ["alloc", "oid"] }. These are each crate's own default lists.

    Other default-features = true overrides remain (libc, cc, pkg-config, serde, tempfile, dunce, libloading, …). They do not break the cook today, but they can cause the same feature mismatch.

    A second gap stays: when core is true (for example the master push run 40531318146), Fast Gate cooks --release. A --release layer cannot serve the test build (test uses dev settings).

    Point 1: where each fix lives

    A correction first: the three inputs that matter are set in this repository. .github/workflows/build-project.yaml passes them to zackees/setup-soldr (forge-ci/setup-soldr v0.9.88): prebuild-deps-flags, cache-key-suffix and save-cache-remote: ${{ github.ref == 'refs/heads/master' }}. setup-soldr builds the key and does the restore and save.

    Cause Repository Change
    3. Test build compiles the dev-dependencies again obs-studio Explicit features instead of default-features = true in the member manifests; prebuild-deps-flags: --profile dev -- --tests for the lanes that build tests. Optional upstream report: the cargo-chef recipe drops default-features = true (second occurrence after #2603).
    1. No macOS/Windows layers obs-studio Decision below
    2. Cache full, evictions #1801 I will add the eviction evidence there

    Point 3: acceptance criterion (for the cause 3 PR)

    On the first master push after the merge that touches rust/, and on the next PR run after it:

    • Fast Gate prints cook-cache-base HIT.
    • The Fast Gate test compile (cargo test --no-run step) compiles at most 10 crates from outside the workspace.
    • Rust Tests (Windows) and Rust Tests (macOS) meet the same two conditions after their layers exist (they depend on the decision below).

    Point 4: Decision needed: layer saving and the Fast Gate cook profile

    1. macOS and Windows layers. Today only master push runs save, and a master push runs these lanes only when its scope selects them. Options:

      • a. Save from PR runs too. Every PR then writes layers; more writes and more evictions in a cache that is already full (fix(ci): reconcile global cache capacity and retain measured warm seeds #1801).
      • b. A cook-only job per platform on master pushes that change Cargo.lock or a Cargo.toml (and on a schedule). It costs one short job per platform when dependencies change. No PR writes.
      • c. Keep the current state; the macOS/Windows lanes compile all dependencies.

      My recommendation: b.

    2. Fast Gate cook profile when core is true. The --release layer serves the release build of the touched targets, but not the test compile. Options: cook --profile dev -- --tests always (the release build then compiles its dependencies), or cook both (two layers, more cache space). This needs your call because of the cache budget.

    Point 5: split

    When you agree, I will:

  4. zackees commented on Oct 27, 2026

    @zackees
    Member

    Decided: take @vpacher's split as written — the cause-3 PR (explicit features instead of default-features = true, plus -- --tests on the lanes that build tests) is this issue's claimable unit, point 4.1 goes with option b, and point 4.2 is one layer per lane, no second layer.

    Reasons, cause 3 first:

    • Your measurement settles cause 3, so it needs no decision. Cases A and B giving the same 55 crates (48 of them dev-dependencies) rules out the separate test profile, and case D's 55 → 1 external crate is the acceptance criterion already in point 3. That is enough to claim and build.
    • 4.1 → b (a cook-only job per platform on master pushes that touch Cargo.lock/a Cargo.toml, plus a schedule). This is the repo's existing cache design, not a new one: saving is gated on github.ref == 'refs/heads/master', and push.yaml is the master cache-warming entry whose in-flight warm run is deliberately kept (perf(ci): fix cache reuse gaps and measure libobs unity/PCH gains #1286, and its cancel-in-progress: false is pinned by ci/test_wf002_concurrency.py). Option a (PR runs save) writes against a cache already at its limit and each extra write becomes an eviction — which is cause 2 of this issue, so it would fight the fix. Option c leaves macOS at 0/6 HIT, which is the symptom being reported.
    • 4.2 → one layer, and keep the release layer for core runs. The repository cache is 10.2 GB across 45 entries against the 10 GB budget tracked by fix(ci): reconcile global cache capacity and retain measured warm seeds #1801 (CACHE-004), and the skill/CI budget treats that as a maintainer-visible steady state. Adding a second layer per lane is exactly the eviction pressure that produces the MISS rows in your table, so: the Fast Gate keeps cooking --release when core is true (the release lanes keep being served by it), and cooks --profile dev -- --tests when it is not; every lane that builds tests passes -- --tests on its own layer. If the release side turns out to cost more than it saves, reopen this — it is one workflow expression and reversible.

    Scope for the first PR (one unit, no macOS/Windows job in it):

    1. the build: Name serde_json's std feature so soldr cook builds again (#2603) #2604 pattern in the member manifests — proptest, base64, memchr, sha2 with explicit feature lists instead of default-features = true;
    2. prebuild-deps-flags: --profile dev -- --tests for the lanes that build tests;
    3. RED/GREEN is your case A vs case D table, re-measured on the head commit;
    4. the eviction evidence goes to fix(ci): reconcile global cache capacity and retain measured warm seeds #1801 as a comment, not into this issue;
    5. the per-platform cook-only job (4.1 b) is a follow-up PR of its own once this one lands.

    The remaining default-features = true overrides you listed (libc, cc, pkg-config, serde, tempfile, dunce, libloading) are worth their own line in #1801 or their own small PR — not this one.

    Marking the issue Ready below so the cause-3 unit can be claimed.

  5. added
    infra
    P2
    size:M
    and removed
    needs-investigation
    on Oct 27, 2026
  6. zackees commented on Oct 27, 2026

    @zackees
    Member

    /ready

    Checked against the definition of Ready (WORKFLOW.md):

    1. Scope is concrete — cause 3 only: the default-features = true overrides plus -- --tests, both named files and both measured by @vpacher.
    2. Acceptance criteria — point 3 of the answer above (cook HIT on the first master push that touches rust/ and the next PR run, at most 10 external crates in the Fast Gate test compile), re-measured as RED/GREEN on the head commit.
    3. Dependencies — none; blockedBy is empty.
    4. No open Decision needed: — 4.1 and 4.2 answered in the Decided: comment above.
    5. Labels — added infra, P2, size:M; this is one PR, not an XL split.

    Infra/CI-only change, so no docs/features.md line.

  7. added
    ready
    on Oct 27, 2026
  8. zackees commented on Oct 27, 2026

    @zackees
    Member

    Claiming: #2661 (the cause-3 unit from the Decided: at 18:36Z)

    Plan (one PR, one unit, no macOS/Windows job in it):

    1. RED: re-measure case A on the head commit — soldr cook --profile dev, then soldr cargo test --workspace --locked --no-run, and count the Compiling <crate> vX lines for crates outside the workspace (expect ~55, 48 of them dev-dependencies).
    2. GREEN: the build: Name serde_json's std feature so soldr cook builds again (#2603) #2604 pattern in the member manifests — explicit feature lists instead of { workspace = true, default-features = true } for proptest, base64, memchr, sha2 — plus prebuild-deps-flags: --profile dev -- --tests on the lanes that build tests.
    3. Re-measure: the Fast Gate test compile then builds ≤10 external crates (vpacher's case D: 1, foldhash).
    4. Report the A vs D table as RED/GREEN. Eviction evidence goes to fix(ci): reconcile global cache capacity and retain measured warm seeds #1801 as a comment, not here. The per-platform cook-only job (4.1 option b) is a follow-up PR of its own.

    First PR: this tick. Infra/CI-only change, so no docs/features.md line.

  9. zackees commented on Oct 27, 2026

    @zackees
    Member

    Opened #2675 for this unit (branch infra/2661-cook-test-deps, base master): the test lanes cook the workspace dev-dependencies and the member manifests declare the four re-enabled defaults as explicit feature lists (the #2604 pattern). RED c6d9b8ad9, GREEN fbc042ffa; local ci/test_*.py sweep green and soldr cargo metadata --locked shows each crate's resolved feature closure equal to its default. PR CI is the end-to-end cook measurement (host soldr 0.9.35 < pinned 0.9.43). The per-platform cook-only job is the follow-up PR; janitor/eviction evidence stays on #1801.

  10. 30 remaining items

  11. zackees commented on Nov 6, 2026

    @zackees
    Member

    Blocked: waiting on cache backend recovery and a controlled warm-run measurement.

    Read all 18 preceding comments and merged #2675, #3128 and #3548. The 2026-11-04 correction is decisive: the historical 123 Compiling lines include replayed lint output; the reported actual HIT test build compiled zero external crates. Do not reopen the profile/dev-dependency work or add cook-only native jobs on that evidence.

    The single most valuable next step is to restore a functioning Fast Gate base save/restore, then measure cook-on-HIT overhead before changing it. Current evidence:

    Exact maintainer/cache-owner request:

    1. Inspect the backend reservation/cache-version/scope for that exact key and the two linked jobs; resolve why restore/list sees nothing while CreateCacheEntry conflicts. Supply backend diagnostics or an upstream setup-soldr fix. Do not just rotate the suffix again without explaining the recurring conflict.
    2. Once a master producer demonstrably saves the layer, provide a subsequent same-key exact-HIT Fast Gate run (same toolchain, lockfile, profile and action pin). Capture setup restore/extract/cook/save durations, soldr load mtime counters, Cargo fingerprint dirty reasons during the cook, and the actual test-build interval. Separate verdict replay output from commands executed in this run; retain SOLDR_RUSTC_WRAPPER=none.
    3. If cook still rebuilds external crates on that HIT, use those dirty reasons to choose an upstream soldr/setup-soldr fix and compare total setup-plus-consumer time on matched inputs. Missing/size-mismatch counters alone do not prove a cause or justify skipping cooking.

    No source/workflow changes or PR: local warm-target timing cannot validate a hosted restore/reservation failure, and the current public jobs cannot validate the remaining warm-HIT hypothesis. Returning the pool slot clean on detached origin/master.

  12. added
    claim-blocked
    on Nov 6, 2026
  13. zackees commented on Nov 6, 2026

    @zackees
    Member

    Status: the overflow tier is being built in forge-ci/soldr

    The floor of this issue is storage: two cook layers per platform (dev + release) cannot fit next to flatpak-builder (2.1 GB) and three zccache-* variants (2.7 GB) inside 10 GB, so every new layer evicts an older one and an evicted layer is a MISS. Raising the limit is billed and, per the issue's own option D, an org decision.

    The chosen direction is overflow instead of growth: GitHub stays level 1, an S3-compatible bucket becomes level 2, and every artifact lives in exactly one of them. Design and open questions: forge-ci/soldr#4099.

    What already exists in soldr (this is why it is an extension, not a new subsystem): .github/actions/setup-soldr/s3_cache.py is a working remote cache — SigV4 S3Client, ListObjectsV2, <family>/<key>.tar.zst layout with actions/cache-compatible prefix restore, seed_l2 for a wiped remote, and an LRU janitor gated to merge_group so concurrent runs never race a sweep. It covered the setup and build families only.

    Landed so far (branch feat/cook-s3-family, 2 commits, 50 tests):

    1. cook is now a cache family — FAMILIES = ("setup", "build", "cook"), and _families_from_env learns INPUT_COOK_CACHE with SETUP_COOK_CACHE_ROOT / _KEY / _RESTORE_PREFIX, the same shape as the other two so restore semantics are identical. Without the family in FAMILIES the janitor never sweeps it, so the bucket would grow unbounded.
    2. plan_demotion(...) — the mirror of the S3 plan_eviction for the level-1 store: least-recently-accessed first, protected keys and entries younger than MIN_EVICT_AGE skipped, and a max_bytes cap that a sweep may not cross. That cap is the cost control for the concern in this thread: demotion is sequential (S3 PUT concurrency 1) and bounded, so one merge-queue run cannot become a multi-gigabyte upload inside its timeout.

    A correction that matters for whoever builds the next piece: the Actions cache REST API has list/delete/usage and no download endpoint. Restoring is the cache service, reachable only from inside a job (ACTIONS_CACHE_URL + ACTIONS_RUNTIME_TOKEN) or via actions/cache/restore with an exact key. So the executor is a workflow step — restore exact key → PUT to S3 → verify → DELETE /actions/caches/{id} — not a REST script. Details and the consequences (non-atomic delete is deliberate, tolerated by xor) are in soldr#4099's follow-up comment.

    Why xor rather than S3-shadow-of-GitHub: shadowing doubles every save (runner egress + PUT latency × parallel lanes) and ages each artifact under two independent eviction clocks. Xor costs one extra restore attempt on a miss and keeps a single writer per artifact.

    What this needs from this repo, once the soldr side lands: consumers pass cook-cache: true (plus the bucket/endpoint secrets) to setup-soldr, and the merge-queue run gets the janitor step. #2661's proposal A (cook-only warm jobs per platform) should be re-measured after the overflow exists — it exists to fight eviction, which overflow removes.

  14. removed
    claim-blocked
    on Nov 6, 2026
  15. moved this from Ready to In progress in obs-rust Multiviewon Nov 6, 2026
  16. zackees commented on Nov 6, 2026

    @zackees
    Member

    Cause 3 is confirmed, and it is a soldr defect rather than a lane-config one

    The "test builds do not use the cooked dependencies (probable)" section asked for confirmation in soldr. Confirmed: soldr cook builds its layer with cargo's default profile settings, while soldr cargo test injects CARGO_PROFILE_TEST_DEBUG=false. Different fingerprints, so the layer is restored (and reports exact=true) and the compiler still rebuilds every external crate.

    Tracked as forge-ci/soldr#4106 with the code references and the fix proposal.

    The measurement, plain cargo, two-dependency crate, fresh CARGO_TARGET_DIR per step, no soldr in the loop:

    step command external crates compiled
    1 cargo build (dev, default debug = true) baseline
    2 CARGO_PROFILE_TEST_DEBUG=false cargo test --no-run ryu, itoa recompiled
    3 cargo test --no-run (test inherits dev, debug = true) none

    Steps 2 and 3 are the same command with a different debug pin. soldr's front door always takes the step-2 path; soldr cook always produces step-3 artifacts. That is your 83 external crates on the lint lane and 66 on rust-test with a HIT.

    A useful side effect of the same bug: debuginfo is the larger half of a dev-profile target/ tree, so the layers that cannot help are also the biggest ones in the cache. Fixing the pin shrinks them — which is real budget relief for the 10 GB ceiling described under cause 2, not just a correctness fix.

    What this means for the rest of the issue

    • Cause 1 (only master pushes save, and they skip macOS/Windows) — unchanged, and it is the dominant term in the table. A macOS layer that is never written cannot be evicted.
    • Cause 2 (10 GB ceiling) — this is where the work I have been landing applies. GitHub stays level 1, an S3-compatible bucket becomes level 2, and each artifact is written to exactly one of them, decided at save time (placement-path / placement-prefer inputs, placement output on setup-soldr's s3-save; guide in docs/CI_CACHE.md, design in cache: cook layers overflow to S3 (level 1 xor level 2) with the merge-queue janitor demoting them forge-ci/soldr#4099). With overflow, one macOS --release save survives a GitHub eviction instead of vanishing — which is the failure your table shows for Rust Tests macOS (0 HIT / 6 MISS).
    • Cause 3 (this comment) — after the pin is fixed, a --profile dev/test layer actually removes the dependency compile, so the 1–3 min per lane on a HIT becomes real instead of theoretical.

    Worth re-measuring the table's HIT column only after both land; until then a HIT and a MISS cost almost the same for dev/test lanes, which makes HIT rate look healthier than it is.

  17. zackees commented on Nov 6, 2026

    @zackees
    Member

    Correction to my previous comment on cause 3

    I overclaimed. This is a walk-back, with the evidence.

    What holds: soldr cook genuinely skips the profile-debug pin that soldr cargo build|test|check injects (there is no chef arm in the front door's subcommand match), and a debug-pin mismatch genuinely forces dependency recompiles — measured with plain cargo, in both directions.

    What I could not show: that this is what your lanes are actually hitting. With the unpatched soldr 0.9.51 on a three-dependency crate:

    sequence external crates compiled by the following soldr cargo test --no-run
    soldr cook → test 0
    soldr cook --release → test 0

    Both zero, on a crate whose cook reported recipe was ephemeral and cross-repo cook sharing disabled — Cargo.lock is not tracked by git. That makes my harness inconclusive rather than exonerating — but it means "cause 3 is confirmed" was not something my measurement supported, so please read that section as still open.

    Two cheaper explanations still on the table, testable from the logs you already cited

    1. Lane-level profile mismatch. Lanes that cook --release and then test in dev/test cannot share artifacts no matter what the debug pin says. Your table already hints at this: release-cook lanes compile 0–27 externals, dev/test lanes compile 66–103 — and the Fast Gate row, which cooks --release and tests, is the one that compiles 111–147 on a HIT.
    2. recipe was ephemeral. If a lane's cook does not pack a shareable layer at all, the pin is irrelevant and the number to look at is whether a layer was ever written — which lands back on cause 1, layers that never exist.

    What I would measure next, in your logs rather than in mine

    For one dev-profile lane, on a run with cook-cache-base HIT, count Compiling <external crate> lines, then flip only the debug pin (CARGO_PROFILE_DEV_DEBUG / CARGO_PROFILE_TEST_DEBUG) and re-count. If the count does not move, the pin is not the cause and cause 3 is a lane-configuration problem; if it moves, soldr#4106 is real at scale and the fix (forge-ci/soldr#4107) closes it.

    The fix is worth landing either way — it makes cook's artifacts provably match the front door — but it should not be sold as a cure until that lane count exists.

  18. zackees commented on Nov 7, 2026

    @zackees
    Member

    Post-pin-bump evidence: the conflict is real, and three jobs fight over one key

    Run 42325420562 is the first master push executed with setup-soldr d01d9bae (the reservation-status fix). It turns the ambiguous skipped-race-precheck into a named cause:

    two-phase-cache: reservation conflict for key=cook-base-v3-linux-x64-glibc-rustc1.98.1-fea2183cb-l7d46f1b3ea231b6d-xlinux-host-v2-soldr…
    

    Three jobs in that one run hit that exact key, and all three got the conflict:

    job cook flags result
    Fast Gate ⚡ --profile dev -- --tests reservation conflict
    Rust Cross Lint 🦀 (aarch64-apple-darwin) --profile dev -- --tests reservation conflict
    Rust Cross Lint 🦀 (x86_64-pc-windows-msvc) --profile dev -- --tests reservation conflict

    If all three conflict, nobody in this run holds the reservation — the holder is outside it. And the cache listing confirms there is no entry to find:

    cook-base-v3-linux-x64-glibc-…-fea2183cb-…-xlinux-host-v2-…   NOT PRESENT
    cook-base-v3-linux-x64-glibc-…-f9e7e4902-…-xlinux-host-v2-…   23 MB  (release key — different family)
    cook-base-v3-linux-x64-glibc-…-f1c7475cf-…-xcross-compile-v1  19 MB
    

    So for the dev+tests key there is a reservation and no artifact. That is an orphaned reservation, not an API failure and not a lost race: nobody raced, and the winner never wrote.

    Two changes worth making, and they are independent

    1. Rotate the key suffix (v2 → v3) as the immediate unblock. It has worked once before (v1 → v2) and the conflict returned, which means the orphan recurs — so this is a mitigation that buys time, not a fix. It also costs one full re-cook of that family, and the key change is a one-line edit in setup-soldr's cook-cache.ts.
    2. Stop having three writers for one key. Fast Gate and both Cross Lint jobs cook the identical dev+tests key in the same run. Even with a healthy reservation only one of them can ever save; the other two produce a conflict, and each pays compress-or-probe cost for nothing. Designating a single saver (Fast Gate) and making the others restore-only removes two-thirds of the reservation traffic on that key and cannot make the outcome worse. It also lowers the parallel-upload cost the issue is concerned about.

    What still needs backend visibility

    Why the reservation is not released. GitHub's reservation is meant to be scoped to the creating job, so a holder that outlives every job in the run is either an orphan from a cancelled job (this repo does have Cancel run (…) steps) or a backend state we cannot inspect from a runner. The runner-side evidence is now unambiguous — three failing reservations and zero artifacts — which is what a GitHub support escalation needs to start from.

    I am not claiming which of those it is. The observable fact is that the layer is unwritable under this key and exactly one job per run could ever have written it.

  19. moved this from In progress to Ready in obs-rust Multiviewon Nov 8, 2026
  20. zackees commented on Nov 23, 2026

    @zackees
    Member

    Re-measured 2026-11-23 — and a scoping correction before anyone builds the wrong thing

    Working the "precache every platform" goal. Four things I verified in the repo today, because two of them change what the work should be.

    1. The queue can never seed a cache — by construction.
    ci.toml sets write-on = ["main", "nightly"] and pr = { mode = "none", … }, with the comment "Only default-branch runs save (write-on); PRs and merge groups restore, so there is no PR delta layer." Merge-queue runs are pure consumers. Any plan that assumes a queue run warms the cache for the next queue run is wrong.

    2. Declared family maxima already consume 6.99 GiB of the 10 GB budget, across 24 families (my own sum over [cache.family] in ci.toml). That is maxima, not live usage, so it is not the same as "no room" — but it does mean a new Windows/macOS family has to come out of someone else's allowance unless it lives outside this budget entirely.

    3. The Windows and macOS app builds do not run on the merge queue at all. macos-build, windows-build, flatpak*, Qt and the native-cache jobs gate on if: fromJSON(needs.check-event.outputs.full), and check-event can only set full for schedule / dispatch / tag / release-branch. So "precache Windows and macOS for the merge queue" is not achievable and not needed — those lanes are cold on the release and nightly path, which is exactly the six families #1801 Phase A retired.

    4. ci.toml already names the intended transport and nobody has built it:

    # Phase A of #1801 (Decided 2026-10-30): the six app-build families … left the Actions cache. They held 5.71 GiB and hit 9 of 42 restores, all on nightly, dispatch and release runs. The release-asset transport (#782) can bring them back outside this budget.

    So the direction is already decided in the contract file. What is missing is the implementation.

    The gap is in soldr, not here

    I filed forge-ci/soldr#4259 for it: soldr save/soldr hydrate exist and crates/soldr-cache/src/cache_lib/load_extract.rs has no http/s3/remote path at all, while crates/soldr-fetch/src/fetch/xwin_cache.rs already pulls a pinned, sha256-addressed cache bundle from the forge catalogue. The fetch half and the save half exist and do not meet.

    That asymmetry is why Windows/macOS caches cannot be shipped today without shelling curl/gh into workflow YAML — transport logic in the workflow, which this repo's "CI is declared, not scripted" rule exists to prevent.

    What I would do next, in order

    1. Land soldr#4259 (publish/fetch verbs keyed by build identity), so the transport is a soldr concern with the existing verification helpers.
    2. Pick the store: the S3 overflow in cache: cook layers overflow to S3 (level 1 xor level 2) with the merge-queue janitor demoting them forge-ci/soldr#4099, the forge catalogue (4.94 GB / 225 entries / 824 MB largest asset, per the producer side), or GHCR as an OCI artifact. Note oras is preinstalled on none of ubuntu-26.04, windows-2025 or macos-15, and macOS runners have no Docker — so any container-based route needs a setup step.
    3. Only then re-add the six app-build families as restore-only from that store on full runs.

    Unrelated but blocking the same goal on Linux

    The prebaked Tier 2 image is public now, but ci/tier2_image.py select returns stock Ubuntu unless mq-heavy-labels is non-empty — i.e. unless vars.FORGE_POOL_LABELS is set, and it is not. The Linux half of "all platforms precached" is one repository variable away and tracked in #5501.

  21. zackees commented on Nov 23, 2026

    @zackees
    Member

    Correction to my comment above — the transport already exists, and it already covers Windows and macOS

    I wrote earlier that Windows/macOS caches "cannot be shipped today without shelling curl/gh into workflow YAML". That was wrong, and I'd rather correct it than leave it to mislead the next person. I checked the workflow instead of the issue text:

    Every job that builds anything — on all three platforms — already configures the S3 remote cache. Counting zackees/setup-soldr@ blocks in build-project.yaml:

    macos-build            setup-soldr=True  save-cache-remote=True
    windows-build          setup-soldr=True  save-cache-remote=True
    rust-tier2-macos       setup-soldr=True  save-cache-remote=True
    rust-tier2-windows     setup-soldr=True  save-cache-remote=True
    rust-tests-macos-build setup-soldr=True  save-cache-remote=True
    rust-tests-windows     setup-soldr=True  save-cache-remote=True
    rust-linux-tier2-build setup-soldr=True  save-cache-remote=True
       … 13 jobs total, every setup-soldr consumer
    

    and the configuration is real, not vestigial (build-project.yaml:1817-1830):

    save-cache-remote: ${{ github.ref == 'refs/heads/master' }}
    s3-bucket: forge-ci
    s3-endpoint: nyc3.digitaloceanspaces.com
    s3-region: nyc3
    s3-cache-limit: 50G
    # S3 remote cache: bucket forge-ci on DO Spaces nyc3; the 50G watermark is
    # enforced only on the merge_group singleton. No bucket/creds = feature off.

    A completed master push (45261370568) shows the credentials arriving (SOLDR_S3_CACHE_ACCESS_KEY: ***), so the path is live, not dormant.

    So the answer to "push build caches into the packaging feature" is: for soldr-managed layers, this is already done and already cross-platform. The Actions cache is the level-1 tier; S3 is level 2, outside the 10 GB budget, exactly as #4099 describes.

    What that leaves as genuinely missing, sharply:

    1. cook layers are not in the S3 families. Per libobs: characterize and extract the video stop traversal #4099, s3_cache.py carries FAMILIES = ("setup", "build"). The 5.71 GiB of app-build cook layers that fix(ci): reconcile global cache capacity and retain measured warm seeds #1801 Phase A retired therefore have no level-2 store — that is the real hole, and it is the one libobs: characterize and extract the video stop traversal #4099 asks to close.
    2. The Linux apt archive (339 MB) is not a soldr layer at all; it lives in the Actions cache and is now topped up by .github/workflows/apt-seed.yaml (ci: seed the Tier 2 apt archive on a schedule #5527).
    3. The Tier 2 prebaked image is public but inert until FORGE_POOL_LABELS is set (CI: build server is idle — 0% of obs-rust merge-queue jobs route to the Dell pool #5501).

    I have retracted the "gap is in soldr" framing accordingly. The soldr-side issue I filed (forge-ci/soldr#4259, save/hydrate have no transport) is still literally true of those two verbs, but it is not the blocker for this issue — the CI's cross-machine need is met by the S3 layer for the layers that use it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2infrareadysize:M

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions