fix: Prime content from overlay when split into partitions
Metadata
Current evaluation
Merged PR #1123 (commit 3540e306), fixing overlay priming with partitions by using stage content and migration state while preserving existing prime state files.
Resolution: closed resolved
Reason: PR #1123 merged as commit 3540e306 with approval and all CI checks passing; it explicitly fixes #1127.
Evaluated by: mr-cal-bot
No scores available.
Issue body
- [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)?
- [x] Have you added an entry to the changelog (`docs/reference/changelog.rst`)?
-----
Rework migrating content from the overlay at the PRIME step.
Due to the new feature to distribute content from the overlay to partitions, the content of the `default` stage directory may not fully reflect the content from the overlay. Consequently, the priming cannot rely on the overlay anymore.
Adopt a new approach relying on the content of the `stage` directory and the stage migration state (to get the list of files/directories coming from the overlay).
This approach is also closer to the standard way to migrate content.
Also make sure to not overwrite existing overlay migration prime state files.
Fixes https://github.com/canonical/craft-parts/issues/1127
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #1123 (commit 3540e306), fixing overlay priming with partitions by using stage content and migration state while preserving existing prime state files. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #1123 (commit 3540e306) fixed priming overlay content with partitions by using stage files and migration state, and closed #1127. | |
| qwen/qwen3.6-35b-a3b | — | — | Merged fix for priming overlay content when split into partitions. Replaces direct overlay reliance with stage directory and migration state. Approved by three reviewers, passed all CI checks, and resolves issue #1127. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged fix for priming overlay content when split into partitions. The change shifts reliance from the overlay to the stage directory and migration state, preventing overwrites and resolving issue #1127. |
Update history
No update history recorded yet.
Related work
-
Related To:
canonical/craft-parts#1127
(confidence 100%)
Overlay-and-partition priming failure fixed by PR #1123.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1127 Failing to prime content with overlay and partitions | craft-parts | closed | Fixed by merged PR canonical/craft-parts#1123 (commit 3540e306), using partition stage files and migration state when priming overlay content. | |
| #664 fix: stage and prime content in all partitions by default | craft-parts | closed | Closed unmerged in favor of an alternative; PR #668 implemented default all-partition staging and priming and merged as commit 85b9ba7a. | |
| #668 fix: stage and prime content in all partitions by default | craft-parts | merged | Merged in #668 as 85b9ba7a: filesets now stage and prime across all partitions by default and reject ambiguous configurations, fixing #650. | |
| #1619 fix: migrate overlay files before running stage or prime (#1617) | craft-parts | merged | Merged as bf3615ca, cherry-picking #1617 so overlay files migrate before stage or prime, preventing build-created directories from shadowing overlay state and breaking priming. | |
| #663 fix: stage and prime content in all partitions by default | craft-parts | closed | PR #663 (fix: stage and prime content in all partitions by default) was closed unmerged in favour of #664; the final fix landed via merged PR #668, commit 85b9ba7a, implementing it in the fileset parser instead of PartSpec validators. | |
| #1617 fix: migrate overlay files before running stage or prime | craft-parts | merged | Merged #1617 as 2d81a4bd, moving overlay migration before stage/prime so build-created directories cannot shadow overlay state and break priming; regression coverage was added. | |
| #121 overlay: migrate overlay data to stage and prime (CRAFT-468, CRAFT-82) | craft-parts | merged | Merged PR #121 as d45d7079, moving overlay data into stage/prime, translating whiteouts and opaque directories to OCI, and cleaning shared overlay data. | |
| #667 fix: make overlay and partition features mutually exclusive | craft-parts | merged | Merged PR #667 as commit 6582b829, making overlay and partitions mutually exclusive and fixing #632. | |
| #1093 Prototype distributing content from overlay to partitions | craft-parts | closed | Prototype PR #1093 (overlay content to partitions) was closed unmerged with 10 unresolved review comments and failing CI. Its work landed separately in #1109 (8810ccc2) and the follow-up fix #1123 (3540e306). | |
| #607 fix(partitions): use base prime dir for getting primed stage packages | craft-parts | closed | Closed unmerged and superseded by the namespaced-partition work merged in #627 via commit 9fe38d11. |