Skip to content

Packages: an update from older metadata gets its build from GitHub - #160

Merged
zakius merged 1 commit into
mainfrom
fix/repo-retention
Nov 30, 2026
Merged

zakius merged 1 commit into
mainfrom
fix/repo-retention

Conversation

@zakius

@zakius zakius commented Nov 30, 2026

Copy link
Copy Markdown
Owner

Discover failed a whole update with a 404: its metadata, from before a publish, named an oganesson build the repository had already deleted (it keeps the 3 newest).

  • dnf/apt: nginx sends a request for a build the server no longer has to the same file in its GitHub release (linux/package/repo-nginx.conf, mounted by repo-compose.yaml, with the GitHub repository filled in by publish-repo.sh). The GitHub assets are byte-identical (tools/from-github.sh checks), so dnf and apt accept them against their metadata checksums.
  • Swap order: www/ gets the new packages first, then the metadata, deleting old files last (--delete-after), so it never has metadata naming a missing package.
  • Windows feed: release.yml uploads -update.exe to the GitHub release, and windows/publish.sh points appcast.xml at that build's copy when the release has it (same SHA-256), else at the site's copy. The site's copy is overwritten by every build of the same Chromium version, so a feed read earlier failed the signature check.

Tested: the nginx config in an nginx:alpine container. Current files return 200; stale .rpm/.deb names return 302 to GitHub, and the followed downloads match the release digests and the checksum a stale PackageKit cache asked for; unknown files return 404. The release lookup in publish.sh was run against real releases. tools/hooks/pre-commit passes. Not run: a full publish-repo.sh / windows/publish.sh (they publish live); WinSparkle following the GitHub redirect is untested (WinInet follows redirects by default).

🤖 Generated with Claude Code

The repository keeps the 3 newest builds, and the last step of publish-repo.sh deleted
the rest, so a machine still on the metadata from before a publish asked for a file that
was gone: Discover and GNOME Software failed the whole update with a 404. nginx now sends
a request for a build the server no longer has to the same file in its GitHub release
(linux/package/repo-nginx.conf), and www/ gets the new packages before the metadata that
names them, with the old files deleted last.

The Windows feed had the same race: the site's update.exe is replaced by every build of
the same Chromium version, so a browser with the feed from before would refuse the new
file's signature. release.yml now uploads update.exe to the GitHub release, and the feed
links to that build's copy there.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
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