fix: stage and prime content in all partitions by default
Metadata
Current evaluation
Superseded by PR #664. The pull request was closed without merging, as the maintainer redirected the partition staging and priming implementation to a follow-up PR.
Suggested action: —
No scores available.
Issue body
- [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)?
-----
When partitions are enabled, all content will be staged and primed in all partitions by "default".
I put "default" in quotes because I'm not setting the default in the [PartSpec pydantic model](https://github.com/canonical/craft-parts/blob/c11570597d4a397aba1744fa08adcd344682246e/craft_parts/parts.py#L59). I can't set the default value outright, but I can modify the data with a `@validator` function. I would probably validate the usage of partitions inside the `PartSpec` model as well.
As a final confusing note, I think @lengau and I both implemented the same validation in different ways: [here](https://github.com/canonical/craft-parts/blob/c11570597d4a397aba1744fa08adcd344682246e/craft_parts/lifecycle_manager.py#L158) and [here](https://github.com/canonical/craft-parts/blob/c11570597d4a397aba1744fa08adcd344682246e/craft_parts/lifecycle_manager.py#L162).
Fixes #650
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Superseded by PR #664. The pull request was closed without merging, as the maintainer redirected the partition staging and priming implementation to a follow-up PR. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Superseded by PR #664. The pull request aimed to fix #650 by staging and priming content in all partitions by default via a Pydantic validator. Closed by the maintainer without merging. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #664 fix: stage and prime content in all partitions by default | craft-parts | closed | Closed in favor of a different solution. The partition validator redesign and default stage/prime content logic was superseded by an alternative implementation. | |
| #668 fix: stage and prime content in all partitions by default | craft-parts | merged | Merged after resolving issue #650 by modifying the fileset parser to stage and prime content across all partitions by default, instead of altering keyword defaults. Ambiguous partition configurations are now rejected. Merged following dependency #669. | |
| #1123 fix: Prime content from overlay when split into partitions | craft-parts | merged | 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. | |
| #607 fix(partitions): use base prime dir for getting primed stage packages | craft-parts | closed | Superseded and closed without merging. The branch remains temporarily for snapcraft's feature/components dependency but will be deleted once issue #620 resolves, with snapcraft switching to feature/namespaced-partitions. |