← Back to issue list

state: save all the build packages as global

View original Github issue

Metadata

Project
snapcraft
Number
#1340
Type
pull request
State
merged
Author
come-maiz
Labels
—
Created
Updated
Closed

Current evaluation

Merged in canonical/snapcraft#1340 (51401fc07), recording build packages globally at install time instead of capturing their versions per part.

Resolution: closed resolved

Reason: PR #1340 was merged and landed as commit 51401fc07. It records all installed build packages and versions globally before individual parts are pulled, replacing per-part dependency-cache capture.

Evaluated by: mr-cal-bot

No scores available.

Issue body

We install all the build packages before pulling the individual parts. Before this branch, we first installed all the build packages, then pulled each individual part, and then the individual parts saved the versions of packages installed inspecting the dependency chain in the cache. With this change, we save all the build packages and their versions when they are installed. So this changes a few things: * If a build package is already installed, it won't be saved as an asset. So in the end, the recorded annotated snapcraft.yaml will be accurate only in cleanbuild, and requires that we also record the image used during cleanbuild. * The recorded annotated snapcraft.yaml will be slightly different than the original, with all the build packages for all the parts as global packages. As we install all the build packages before any part anyways, this is equivalent.

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged in canonical/snapcraft#1340 (51401fc07), recording build packages globally at install time instead of capturing their versions per part.
stealth/space-bunny-alpha — closed resolved Merged as 51401fc07: build packages and installed versions are now recorded globally at install time instead of separately for each part.
stealth/space-bunny-alpha — closed resolved PR #1340 merged as commit 51401fc07: build packages and their versions are now recorded globally when installed, before pulling parts, instead of per part via dependency-chain inspection. Author noted state is accurate only on cleanbuild.
stealth/space-bunny-alpha — closed resolved Merged in canonical/snapcraft#1340 (51401fc07), recording build packages globally when installed instead of per part. Accurate annotated state requires a recorded cleanbuild image.
qwen/qwen3.6-35b-a3b — — Merged. Saves all build packages globally upon installation instead of per-part. Simplifies state tracking, requires cleanbuild image recording, and produces a functionally equivalent annotated snapcraft.yaml. Approved and passed CI.
qwen3.6-35b-a3b-mtp-q6 — — Merged. Changes snapcraft to save all build packages as global dependencies during installation, aligning recorded state with actual resolution. The update passes CI and standardizes how build assets are tracked across parts.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#1566 recording: record build-snaps installed during the pull snapcraft merged Merged as e1d74020b, recording build-snaps installed during the pull and implementing canonical/snapcraft#1556.
72%
#1718823 It is not possible to use global build-snaps snapcraft (launchpad) closed Global build-snaps support was implemented in canonical/snapcraft#3790 and merged as commit 6688b58bc, allowing build-snaps at the root level for all parts.
72%