Skip to content

nuxt-cloudflare: cache restore for extra-gate and preview; drop retired Blacksmith/lightweight runs-on arms - #249

Merged
narduk-durable-agent-sessions[bot] merged 2 commits into
mainfrom
stop-two-wasted-dependency-i-1419
Nov 10, 2026
Merged

narduk-durable-agent-sessions[bot] merged 2 commits into
mainfrom
stop-two-wasted-dependency-i-1419

Conversation

@narduk-durable-agent-sessions

@narduk-durable-agent-sessions narduk-durable-agent-sessions Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Refs narduk-enterprises/fleet#1431

Two commits: A (dependency-cache restore) and B (dead routing arms).

A. extra-gate and preview restore the dependency cache

Both jobs ran pnpm install / npm ci with no restore, while build, checks, e2e, deploy-dry-run and fast restore node-deps-<os>-<arch>-<pm>-<lockfile hash>. Each now gets the same restore-only pair checks uses, before Configure package registry auth. No cache/save was added: build owns the default-branch write.

      - name: Resolve dependency cache directory
        id: dep-cache-dir
        if: runner.environment == 'github-hosted'
        run: |  # sets the pnpm store / npm cache to $(dirname $GITHUB_WORKSPACE)/.ci-cache/..., emits path=
      - name: Restore dependency cache
        id: dep-cache
        if: runner.environment == 'github-hosted'
        uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
        with:
          path: ${{ steps.dep-cache-dir.outputs.path }}
          key: node-deps-${{ runner.os }}-${{ runner.arch }}-${{ inputs.package-manager }}-${{ hashFiles(...pnpm-lock.yaml, ...package-lock.json) }}
          restore-keys: |
            node-deps-${{ runner.os }}-${{ runner.arch }}-${{ inputs.package-manager }}-

The if: runner.environment == 'github-hosted' guard is the repo's rule R8 (a self-hosted guest's package store is shared and persistent; tarballing it is unsound), so the restore only helps hosted runners, i.e. public callers. A private caller on self-hosted linux-ci skips both steps by design. That is the same behaviour the other jobs have.

B. Blacksmith and lightweight arms removed from runs-on

Removed: every arm keyed on vars.BLACKSMITH_RUNNERS_ENABLED, vars.BLACKSMITH_LINUX_LABEL and vars.CI_LIGHTWEIGHT_RUNNER (56 runs-on lines), the Blacksmith-overflow comment blocks, the stale "Blacksmith since 2026-09-29" comment in red-main-listener.yml, and the README text that documented them as live. Tests that asserted the variables now assert they are ignored.

Before/after, red-main-listener.yml job reconcile (the shortest case):

before (2347 chars)
runs-on: ${{ fromJSON(toJSON(github.event.repository.private) != 'true' && toJSON(github.event.repository.private) != 'false' && '"missing-repository-visibility-do-not-run"' || (toJSON(github.event.repository.private) == 'false' && '"ubuntu-latest"' || ((toJSON(github.event.repository.private) == 'false' || vars.CI_LIGHTWEIGHT_RUNNER == '"self-hosted"' || startsWith(vars.CI_LIGHTWEIGHT_RUNNER, '[') && contains(fromJSON(vars.CI_LIGHTWEIGHT_RUNNER || '[]'), 'self-hosted') || startsWith(vars.CI_LIGHTWEIGHT_RUNNER, '{') && (fromJSON(vars.CI_LIGHTWEIGHT_RUNNER || '[]').labels == 'self-hosted' || startsWith(toJSON(fromJSON(vars.CI_LIGHTWEIGHT_RUNNER || '[]').labels), '[') && contains(fromJSON(vars.CI_LIGHTWEIGHT_RUNNER || '[]').labels, 'self-hosted')) || startsWith(vars.CI_LIGHTWEIGHT_RUNNER, '"blacksmith-')) && vars.CI_LIGHTWEIGHT_RUNNER) || (vars.BLACKSMITH_RUNNERS_ENABLED == 'true' && (((toJSON(github.event.repository.private) == 'false' || inputs.runner == '"self-hosted"' || startsWith(inputs.runner, '[') && contains(fromJSON(inputs.runner || '[]'), 'self-hosted') || startsWith(inputs.runner, '{') && (fromJSON(inputs.runner || '[]').labels == 'self-hosted' || startsWith(toJSON(fromJSON(inputs.runner || '[]').labels), '[') && contains(fromJSON(inputs.runner || '[]').labels, 'self-hosted')) || startsWith(inputs.runner, '"blacksmith-')) && inputs.runner) || toJSON(github.event.repository.private) != 'false' && '{"group":"linux-ci","labels":["self-hosted","Linux","X64","proxmox","linux-ci"]}' || '"ubuntu-latest"') != '"ubuntu-latest"' && format('"{0}"', startsWith(vars.BLACKSMITH_LINUX_LABEL, 'blacksmith-') && vars.BLACKSMITH_LINUX_LABEL || 'blacksmith-2vcpu-ubuntu-2404') || (((toJSON(github.event.repository.private) == 'false' || inputs.runner == '"self-hosted"' || startsWith(inputs.runner, '[') && contains(fromJSON(inputs.runner || '[]'), 'self-hosted') || startsWith(inputs.runner, '{') && (fromJSON(inputs.runner || '[]').labels == 'self-hosted' || startsWith(toJSON(fromJSON(inputs.runner || '[]').labels), '[') && contains(fromJSON(inputs.runner || '[]').labels, 'self-hosted')) || startsWith(inputs.runner, '"blacksmith-')) && inputs.runner) || toJSON(github.event.repository.private) != 'false' && '{"group":"linux-ci","labels":["self-hosted","Linux","X64","proxmox","linux-ci"]}' || '"ubuntu-latest"')))) }}
runs-on: ${{ fromJSON(toJSON(github.event.repository.private) != 'true' && toJSON(github.event.repository.private) != 'false' && '"missing-repository-visibility-do-not-run"' || (toJSON(github.event.repository.private) == 'false' && '"ubuntu-latest"' || (((toJSON(github.event.repository.private) == 'false' || inputs.runner == '"self-hosted"' || startsWith(inputs.runner, '[') && contains(fromJSON(inputs.runner || '[]'), 'self-hosted') || startsWith(inputs.runner, '{') && (fromJSON(inputs.runner || '[]').labels == 'self-hosted' || startsWith(toJSON(fromJSON(inputs.runner || '[]').labels), '[') && contains(fromJSON(inputs.runner || '[]').labels, 'self-hosted')) || startsWith(inputs.runner, '"blacksmith-')) && inputs.runner) || toJSON(github.event.repository.private) != 'false' && '{"group":"linux-ci","labels":["self-hosted","Linux","X64","proxmox","linux-ci"]}' || '"ubuntu-latest"'))) }}

Not changed: CI_LINUX_RUNNER (live), the lightweight-runner caller input (a breaking-input removal, test_nuxt_input_freeze.py pins it), and the startsWith(<input or CI_LINUX_RUNNER>, '"blacksmith-') predicates. Those accept a caller-supplied or live-variable label, so deleting them changes resolution if any caller passes one. Follow-up, needs a caller survey.

Verification

  • Equivalence: the 50 job runs-on expressions at the pre-B commit and now, evaluated with the interpreter from scripts/test_runner_default.py over visibility true/false/missing x 8 event shapes (PR, draft, Dependabot, lane bot, T2 repo, schedule, nightly dispatch, push) x 5 CI_LINUX_RUNNER values x runner-input variants (default, linux-ci, other fleet, blacksmith label, ubuntu-latest, self-hosted string/array/object, macOS) x fast-parallel/preview-checks/production-output-directory, with the three retired variables empty: 110160 evaluations, 0 mismatches. (The harness found two real bugs in my first rewrites before this run.)
  • scripts/precheck at a12a677 (the head 35fa367 adds only comment edits, after which actionlint, lint_callables.py and the six routing tests were re-run green): exit 0, 43 PASS lines (native-alerts actionlint build 0.27s, actionlint 2.33s, lint_callables.py 1.03s, every scripts/test_*.py including test_actionlint_native_permissions.py and test_runner_default.py 59s).
  • Includes test_runner_default.py, test_cache_paths.py (13 cache sites, 0 failures), test_apple_gate.py, test_reusable_browser_tests.py, test_preview_gate.py, test_production_upload.py.

Assumed

Org variables are unreadable from here: assumed BLACKSMITH_RUNNERS_ENABLED and CI_LIGHTWEIGHT_RUNNER are unset or false in every caller repo (Blacksmith disabled 2026-10-06, D-BLACKSMITH-7; lightweight class retired 2026-10-13, D-RUNNER-LIGHTWEIGHT-RETIRE-1). A caller that still sets either now gets the default route instead of the dead one.

🤖 Generated with Claude Code

loganrenz and others added 2 commits November 10, 2026 14:25
Both jobs ran a package install with no cache restore while build, checks,
e2e, deploy-dry-run and fast restore node-deps-<os>-<arch>-<pm>-<lockfile>.
Add the same restore-only pair (resolve directory, restore) before the
install. No second save: build owns the default-branch write. Hosted
runners only, as everywhere else (R8).

Refs narduk-enterprises/fleet#1431

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Blacksmith was disabled 2026-10-06 (D-BLACKSMITH-7) and the lightweight
class retired 2026-10-13 (D-RUNNER-LIGHTWEIGHT-RETIRE-1). Delete the
runs-on arms keyed on vars.BLACKSMITH_RUNNERS_ENABLED,
vars.BLACKSMITH_LINUX_LABEL and vars.CI_LIGHTWEIGHT_RUNNER, their comment
blocks, and the README text documenting them. With those variables unset
every job resolves exactly as before (110160 old-vs-new evaluations, 0
mismatches). CI_LINUX_RUNNER, the lightweight-runner input and the
caller-supplied "blacksmith- predicates are untouched. Tests that asserted
the variables now assert they are ignored.

Refs narduk-enterprises/fleet#1431

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@narduk-durable-agent-sessions
narduk-durable-agent-sessions Bot force-pushed the stop-two-wasted-dependency-i-1419 branch from a12a677 to 35fa367 Compare November 10, 2026 15:03
@narduk-durable-agent-sessions
narduk-durable-agent-sessions Bot enabled auto-merge (squash) November 10, 2026 15:04
@narduk-durable-agent-sessions
narduk-durable-agent-sessions Bot merged commit 426d625 into main Nov 10, 2026
4 checks passed
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