fix: skip injecting snaps from host when cross-building
Metadata
Current evaluation
Closed as redundant after the same cross-build snap-injection fix merged in canonical/craft-application#1037 via commit 16bd7ac3.
Resolution: closed superseded
Reason: PR #1037 had already merged commit 16bd7ac3, which skips host snap injection when host and guest architectures differ. PR #1064 was therefore closed as redundant.
Evaluated by: mr-cal-bot
No scores available.
Issue body
- [ ] Have you followed the guidelines for contributing?
- [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)?
- [ ] Have you successfully run `make lint && make test`?
- [ ] Have you added an entry to the changelog (`docs/reference/changelog.rst`)?
---
CRAFT-5118
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed superseded | Closed as redundant after the same cross-build snap-injection fix merged in canonical/craft-application#1037 via commit 16bd7ac3. | |
| stealth/space-bunny-alpha | — | closed superseded | Closed as redundant; the cross-build host-snap fix had already merged via canonical/craft-application#1037 in commit 16bd7ac3. | |
| stealth/space-bunny-alpha | — | closed superseded | Closed as redundant: the same cross-build host-snap fix had already merged via canonical/craft-application#1037, commit 16bd7ac3. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed after passing CI checks, implementing a fix to skip injecting host snaps during cross-building. Addresses CRAFT-5118. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without merge. The proposed fix to skip injecting host snaps during cross-building was rejected. |
Update history
No update history recorded yet.
Related work
-
Superseded By:
canonical/craft-application#1037
(confidence 100%)
Merged PR implementing the same cross-build host-snap injection fix.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1570414 Snapcraft doesn't check if cross-compiling before trying to install necessary tools | snapcraft (launchpad) | closed | Fixed: cross-build packages are now only installed when actually cross-compiling. Resolved by merged PR canonical/snapcraft#451 (commit 96b811df1), released in Snapcraft 2.8.1 via #465; LP bug closed. | |
| #467 fix: inject aliased snaps into build environment | craft-application | merged | Merged PR #467 (77a3582b) injects snaps under their aliased names, fixing #411 and the Snapcraft #4683 reproducer. | |
| #1059 Packing with CRAFT_BUILD_ON can fail when installing registered snaps | craft-application | open | Cross-architecture packing with registered snaps could inject incompatible host snaps; commit 16bd7ac3 now skips host snap injection when architectures differ. | |
| #1037 feat(ProviderService): don't inject snaps if the host and guest architectures differ | craft-application | merged | Merged PR #1037 as commit 16bd7ac3, preventing host application-snap injection for cross-architecture guests and using Snap Store installation instead. | |
| #1998100 Randomly I get "failed to inject host's snap 'snapcraft' into target environment." errors | snapcraft (launchpad) | closed | Random host-snap injection failures were fixed by canonical/craft-providers PR #182 and released in Snapcraft 7.3. | |
| #1775911 Only load the project code on the to-build host | snapcraft (launchpad) | closed | Fixed via snapcraft/snapcraft#2222 (commit b2bd6b776), associated with Launchpad #1788667, updating LXD snap injection for remote builds. | |
| #1983009 Snapcraft 7.1.0 fails to find stage package when cross-compiling | snapcraft (launchpad) | closed | Fixed by canonical/snapcraft#3416 (commit 8f418e3d9), restoring core20 behavior so stage packages come from build-on repositories during cross-compilation. | |
| #1782778 Improve installation/injection logic for snapcraft (and core) | snapcraft (launchpad) | closed | Installation and host-injection logic was resolved in canonical/craft-providers PR #45, merged as commit 3573b67 under CRAFT-253. | |
| #1577 lxd: don't inject local snaps on a different arch | snapcraft | merged | Merged in snapcraft#1577 via commit 5cef61310, preventing incompatible local snaps from being injected into cross-architecture LXD builds and using store snaps instead. | |
| #1746612 Snapcraft cleanbuild doesn't work if you're not using the LXD snap | snapcraft (launchpad) | closed | Closed after the missing hostfs behavior was fixed upstream in lxc/lxd#4183. Snapcraft PR #1912 offered a workaround but was not merged. |