← Back to issue list

`primed-stage-packages` in `manifest.yaml` loses architecture information

View original Github issue

Metadata

Project
snapcraft
Number
#5998
Type
issue
State
open
Author
Saviq
Labels
Created
Updated
Closed

Current evaluation

primed-stage-packages in manifest.yaml drops foreign-arch qualifiers (e.g. :i386) while stage-packages keeps them. Root cause is in craft-parts origin tracking; a craft-parts PR (#1558) has since fixed it.

Suggested action: keep open

Reason: A maintainer (gcomneno) triaged this on 2026-03-21 and identified the root cause as cross-repo: craft-parts' origin tracking uses `dpkg-deb --show --showformat=${Package}=${Version}`, dropping the `:i386`/`:armhf` qualifier. A craft-parts commit (0b6a556a, PR #1558) titled 'packages: preserve architecture in primed stage packages' appears to address exactly this, so the issue should stay open pending verification that the fix is released in a snapcraft-supported craft-parts version.

Impact: 50 Quick Win: 30.0 Staleness: 35 Complexity: 40 Confidence: 80 Support Request: 5

Issue body

### Check existing issues - [x] I've verified that this bug isn't described by any existing issues. ### Bug description Look at `/snap/mesa-2404/current/snap/manifest.yaml`: ``` $ cat /snap/mesa-2404/current/snap/manifest.yaml | yq '.parts[] | .stage-packages' | sort -u | wc -l 140 $ cat /snap/mesa-2404/current/snap/manifest.yaml | yq '.primed-stage-packages' | sort -u | wc -l 64 ``` Looking closer, the packages are listed without architecture. ### Steps to reproduce With the attached YAML: ``` $ SNAPCRAFT_BUILD_INFO=1 snapcraft --verbose $ unsquashfs base-cleanup_0.1_amd64.snap $ cat squashfs-root/snap/manifest.yaml | yq '.parts[] | .stage-packages' | sort -u - gcc-14-base:i386=14.2.0-4ubuntu2~24.04 - libc6:i386=2.39-0ubuntu8.6 - libgcc-s1:i386=14.2.0-4ubuntu2~24.04 - xz-utils=5.6.1+really5.4.5-1ubuntu0.2 $ cat squashfs-root/snap/manifest.yaml | yq '.primed-stage-packages' | sort -u - gcc-14-base=14.2.0-4ubuntu2~24.04 - libc6=2.39-0ubuntu8.6 - libgcc-s1=14.2.0-4ubuntu2~24.04 - xz-utils=5.6.1+really5.4.5-1ubuntu0.2 ``` ### Environment Ubuntu 25.10 Snapcraft 8.13.2 ### snapcraft.yaml ```yaml name: base-cleanup base: core24 version: '0.1' summary: Cleanup verifier description: Cleanup verifier grade: devel confinement: devmode package-repositories: - type: apt url: http://archive.ubuntu.com/ubuntu suites: [noble] components: [main] architectures: [i386] key-id: F6ECB3762474EDA9D21B7022871920D1991BC93C key-server: keyserver.ubuntu.com parts: my-part: plugin: nil stage-packages: - xz-utils - xz-utils:i386 ``` ### Log output ```shell <!-- Provide any relevant logging. This field automatically renders as a log, so you don't need to add special formatting. --> ```

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.8-27b
Impact: 50
Quick Win: 30.0
Staleness: 35
Complexity: 40
Confidence: 80
Support Request: 5
keep open primed-stage-packages in manifest.yaml drops foreign-arch qualifiers (e.g. :i386) while stage-packages keeps them. Root cause is in craft-parts origin tracking; a craft-parts PR (#1558) has since fixed it.
qwen/qwen3.8-27b
Impact: 50
Quick Win: 30.0
Staleness: 45
Complexity: 40
Confidence: 75
Support Request: 10
keep open primed-stage-packages in manifest.yaml drops foreign-arch qualifiers (e.g. :i386). Root cause identified in craft-parts origin tracking; likely fixed by craft-parts PR #1558 (preserve architecture in primed stage packages).
qwen/qwen3.6-35b-a3b
Staleness: 55
Complexity: 45
Confidence: 85
Support Request: 10
needs triage primed-stage-packages in manifest.yaml drops architecture suffixes compared to stage-packages. Root cause likely in craft-parts dpkg parsing. Issue lacks labels and maintainer response.
qwen3.6-35b-a3b-mtp-q6
Staleness: 70
Complexity: 40
Confidence: 80
Support Request: 0
needs triage primed-stage-packages in manifest.yaml strips architecture suffixes compared to stage-packages. Clear reproduction steps exist, but the issue lacks labels and official maintainer triage.
qwen3.6-35b-a3b-mtp-q6
Staleness: 45
Complexity: 35
Confidence: 90
Support Request: 0
needs triage primed-stage-packages in manifest.yaml drops architecture suffixes like :i386. Investigation traces the loss to craft-parts stripping arch info via dpkg-deb. Root cause is in craft-parts. Issue awaits upstream fix.

Update history

No update history recorded yet.

Related work

  • Likely Fixed By: canonical/craft-parts#1558 (confidence 85%)

    craft-parts commit 0b6a556a 'packages: preserve architecture in primed stage packages (#1558)' directly targets the reported behavior where primed-stage-packages lose the architecture qualifier.

Related issues

Issue Project State Summary Similarity
#5552 `primed-stage-packages` isn't in manifest.yaml when using override-prime snapcraft open primed-stage-packages missing from manifest.yaml when override-prime is used; triaged bug blocked by upstream craft-parts issue #1122 which remains open. No fix implemented in ~15 months.
76%
#1557 fix(deb): preserve architecture in primed stage packages craft-parts closed Closed by author and superseded by pull request #1558, which implements the same fix for preserving foreign-architecture package names during deb metadata extraction.
72%