Skip to content

ci: re-fetch moving-ref package downloads each build (fixes stale webui) - #105

Merged
widgetii merged 1 commit into
masterfrom
ci/refresh-moving-ref-dl
Jun 15, 2026
Merged

widgetii merged 1 commit into
masterfrom
ci/refresh-moving-ref-dl

Conversation

@widgetii

Copy link
Copy Markdown
Member

Problem (empirically confirmed)

builder caches BR2_DL_DIR (/tmp/builder-dl) under a monthly key
(builder-dl-$(date +%m)), and actions/cache only saves on a key miss — so the
first build of the month freezes the download dir for weeks. Packages pinned to a
moving ref (VERSION = HEAD / a branch, or the majestic-webui rolling dist
release asset) download as a constant <pkg>-<ref>.tar.gz, so buildroot finds the
frozen tarball and never re-fetches — defeating the clean firmware-HEAD re-clone that
builder does on every run specifically for freshness.

I verified this on real nightly assets:

OPENIPC_VERSION=2.6.06.14, both built 2026-06-14 bootstrap.min.css settings JS webui age
firmware nightly (ssc335de) 101 KB (purged) mj-settings.js present current
builder nightly (gk7202v300) 232 KB (full) mj-settings.js absent ~2 weeks stale

Same firmware source on both; the only difference is firmware has this cache-bust and builder doesn't.

Fix

A Refresh moving-ref package downloads step right after Setup dl cache in both
master.yml and build-one.yml, dropping *-{HEAD,master,main,dist}.tar.gz from
/tmp/builder-dl before the build so buildroot re-fetches the current ref. Content-
addressed packages (S3 / semver / SHA pins) keep their cache. Mirrors the same fix
already in OpenIPC/firmware.

🤖 Generated with Claude Code

builder caches BR2_DL_DIR (/tmp/builder-dl) under a monthly key (date +%m), and
actions/cache only saves on a key miss, so the first build of the month freezes it for
weeks. Packages pinned to a moving ref (VERSION = HEAD/branch, or the majestic-webui
`dist` release asset) download as a constant <pkg>-<ref>.tar.gz, so buildroot keeps
reusing the stale tarball — defeating the clean firmware-HEAD re-clone builder does for
freshness.

Empirically, a 2026-06-14 builder nightly shipped a ~2-week-old majestic-webui (full
bootstrap.min.css, no mj-settings.js) while the firmware nightly of the same day shipped
the current slim UI. Drop *-{HEAD,master,main,dist}.tar.gz before each build (master.yml
+ build-one.yml) so buildroot re-fetches the current ref. Mirrors the same fix in
OpenIPC/firmware.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@widgetii
widgetii merged commit 97356e0 into master Jun 15, 2026
@widgetii
widgetii deleted the ci/refresh-moving-ref-dl branch June 15, 2026 06:32
widgetii added a commit that referenced this pull request Jun 28, 2026
PR #105 added a "Refresh moving-ref package downloads" step that drops
*-{HEAD,master,main,dist}.tar.gz before each build so buildroot re-fetches
the current ref. That fixed the majestic-webui-dist.tar.gz staleness (the
*-dist.tar.gz case), but it never matched majestic itself.

majestic downloads from S3 as majestic.<family>.<variant>.master.tar.bz2
(majestic.mk) — a DOT separator, .tar.bz2, and an S3 host the old pattern
deliberately spared as "content-addressed". But that S3 object is a moving
`master` build, re-uploaded on every majestic CI run, with no .hash to force
a refetch. So it stayed frozen in the monthly builder-dl cache while the
webui refreshed — the exact desync that shipped a pre-x-groups majestic in a
t31 lite image against the current webui, blanking the settings page with
"No settings groups in schema."

Broaden the eviction to a regex covering both -ref and .ref separators across
gz/bz2/xz, so majestic.*.master.tar.bz2 and majestic-webui-dist.tar.gz are
both dropped while semver/SHA-pinned tarballs keep their cache.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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