Repository navigation
feat: the gate proves the package's metadata - #8
Merged
Merged
Conversation
added 2 commits
October 22, 2026 07:25
The operator's decision: check the package's metadata, not its build. The package itself is the release's business and costs minutes; what it *says* is the gate's. The new step, 'package-metadata', runs the package's own package() function against the tree the gate has built, in a scratch directory. A source that is not there makes install fail, so the file list is proven to exist rather than parsed and hoped for — and the loops in it (the icon sizes) are resolved by the package itself. It then asks the question that matters: do the package's dependencies bring the libraries its binaries link? The libraries come from the binaries' own NEEDED entries, and the packages that provide them are looked for in the dependencies' closure — because a distribution may split a package (CachyOS splits libgcc_s out of gcc-libs), and the question is not whether the names match but whether the package works on a machine that installed its dependencies. Measured: the check finds what it is meant to find. Taking 'pacman' out of the dependencies makes it fail, naming pacman and libarchive — the library the CLI links, which came in through pacman. The Flatpak backend is the optional part, and its libraries belong to the optional dependency that switches it on.
The lockfile's currency and the package's metadata: the gate covered the paths that were easy to cover, and the paths that matter — the artifact that ships, and the lockfile that names it — were outside it. The record keeps the measurements, including the one that shows the metadata check has teeth.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The operator's decision: check the package's metadata, not its build. The package itself is the release's business and costs minutes; what it says is the gate's.
The gap
scripts/verifybuilds the Zig binaries and the Rust binaries. Nothing built the package — the artifact that ships — so a packaging defect surfaced only when the machine was asked to install it:and the cause was three flags that makepkg inherits from the build machine (PR #7). The flags' cause is now covered by the
build-flagsstep. What is still unproven is the package's own metadata: its file list, and the dependencies it names.The step
package-metadataruns the package's ownpackage()function against the tree the gate has built, in a scratch directory. A source that is not there makesinstallfail, so the file list is proven to exist rather than parsed and hoped for — and the loops in it (the icon sizes) are resolved by the package itself.It then asks the question that matters: do the package's dependencies bring the libraries its binaries link?
The libraries come from the binaries' own
NEEDEDentries. The packages that provide them are looked for in the dependencies' closure, because a distribution may split a package — CachyOS splitslibgcc_sout ofgcc-libs— and the question is not whether the names match but whether the package works on a machine that installed its dependencies.The Flatpak backend is the optional part, and its libraries belong to the optional dependency that switches it on.
It has teeth
Taking
pacmanout of the dependencies makes the step fail, namingpacmanandlibarchive— the library the CLI links, which came in throughpacman:The gates
scripts/verify— PASSED, the step takes 5 s.scripts/ci-replay— PASSED, 109 s: in the container the step builds the release binary (it needs the artifact'sNEEDEDentries), which the later release-build step then reuses, so the total is unchanged.The record:
evidence/runs/gate-gaps-20261022/.