Use the platform in snap names to prevent overwrites
Metadata
Current evaluation
Fixed by merged PR canonical/snapcraft#5588 (commit 57080e5c7), using platform names in Core24 snap filenames to prevent same-architecture artifacts from overwriting each other.
Resolution: closed resolved
Reason: PR #5588 was merged as commit 57080e5c7 and changed snap filenames to use the platform name, resolving the collision.
Evaluated by: mr-cal-bot
No scores available.
Issue body
### What needs to get done
Snapcraft should use the platform name in the snap filename rather than the build-for arch. ([source](https://github.com/canonical/snapcraft/blob/5e21a93fc2ab8bea9e49b0cf941c10adff0f5bf1/snapcraft/pack.py#L65))
### Why it needs to get done
Using the platforms entry:
```yaml
name: hello
base: core24
version: '0.1'
summary: hello
description: hello
grade: devel
confinement: devmode
platforms:
release:
build-on: [amd64]
build-for: [amd64]
debug:
build-on: [amd64]
build-for: [amd64]
parts:
my-part:
plugin: nil
```
and building on amd64 will create 2 snaps, both named `hello_0.1_amd64.snap`. The second snap file will silently overwrite the first.
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Fixed by merged PR canonical/snapcraft#5588 (commit 57080e5c7), using platform names in Core24 snap filenames to prevent same-architecture artifacts from overwriting each other. | |
| stealth/space-bunny-alpha | — | closed resolved | Fixed in merged PR #5588 (57080e5c7): Core24 snap filenames now use the platform name, avoiding collisions between platforms targeting the same architecture. | |
| stealth/space-bunny-alpha | — | closed resolved | Fixed in merged PR #5588 (commit 57080e5c7): Core24 snap filenames now use platform names, preventing collisions between platforms targeting the same architecture. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without implementation. The enhancement was tracked internally via Jira and noted as a requirement for stabilizing the snapcraft test command. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without implementation. Deferred to internal Jira tickets and noted as a requirement for snapcraft test stability. Abandoned pending future development. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without implementation. The enhancement to use platform names in snap filenames to prevent overwrites was deferred, noted as a requirement for snapcraft test to exit experimental status. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Closed without implementation. Identified as a requirement for stabilizing snapcraft test, but no fix was merged. The enhancement remains deferred. |
Update history
No update history recorded yet.
Related work
-
Likely Fixed By:
canonical/snapcraft#5588
(confidence 100%)
Merged commit 57080e5c7 implements the requested filename change.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #5588 fix!: use platform name in snap filename | snapcraft | merged | Merged PR #5588 (57080e5c7) changed Core24 snap filenames to use platform names, preventing same-architecture platforms from overwriting each other; fixes #5399. | |
| #5538 Name snap files after the platform | snapcraft | closed | Closed as duplicate of #5399; merged PR #5588 (commit 57080e5c7) fixed Core24 filename collisions by including platform names in snap filenames. | |
| #4630 feat: add platforms and drop architectures for core24 | snapcraft | merged | Merged as canonical/snapcraft#4630 (f771a4ab8), adding optional core24 platform selection and removing legacy architectures, with host build defaults. | |
| #11 fix: --platform no longer allowed in snapcraft | starflow | merged | Merged PR #11 (commit 4d6936e) removed the unsupported --platform option from the snapcraft command, aligning the workflow with Snapcraft's updated CLI. | |
| #5790 fix: resolve core20 architecture shorthand multi-snap naming issue | snapcraft | closed | External PR to fix core20 shorthand architecture producing multi-arch snaps was declined by maintainer (bepri) as better fixed internally; superseded by merged PR #5818 (commit f0a732be3) adding a warning, shipped in 8.13.0. |