Multiple `charmcraft pack` fail on mismatching platforms
Metadata
Current evaluation
Charmcraft 4.2.0+ reuses a managed LXD instance from a prior `charmcraft pack` of a different project, causing the second pack to fail with 'Platform not found in the project definition' when platform sets differ. Still reproducible on 4.3.1 per reporter's 2026-08-17 comment; no maintainer response or labels yet.
Suggested action: needs triage
Reason: The issue has no labels, no assignee, and no maintainer comments — only the reporter's own follow-up (2026-08-17) confirming it persists on 4.3.1. It's a clear regression (worked in 4.0.1, broke in 4.2.0) with a concrete reproducer (two consecutive `charmcraft pack` calls with different platform sets), so it needs maintainer triage rather than closure. Complexity is moderate because the root cause likely lies in craft-providers' instance/base-instance reuse logic (the 'Creating instance from base instance' step) rather than charmcraft's own code, which I could not locate in this repo's source.
Issue body
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.8-27b |
Impact:
65
Quick Win:
26.0
Staleness:
15
Complexity:
60
Confidence:
70
Support Request:
5
|
needs triage | Charmcraft 4.2.0+ reuses a managed LXD instance from a prior `charmcraft pack` of a different project, causing the second pack to fail with 'Platform not found in the project definition' when platform sets differ. Still reproducible on 4.3.1 per reporter's 2026-08-17 comment; no maintainer response or labels yet. | |
| qwen/qwen3.6-35b-a3b |
Staleness:
25
Complexity:
45
Confidence:
90
Support Request:
10
|
needs triage | Regression in Charmcraft 4.2.0+ where packing an ancillary charm fails with a platform mismatch error when run after a primary charm with different platforms. Currently unlabelled and awaiting maintainer review. | |
| qwen3.6-35b-a3b-mtp-q6 |
Staleness:
70
Complexity:
40
Confidence:
85
Support Request:
10
|
needs triage | Regression in Charmcraft 4.2.0 where packing a secondary charm fails with a platform mismatch error when run after a primary charm. Untriaged, no maintainer response after 110 days. | |
| qwen3.6-35b-a3b-mtp-q6 |
Staleness:
75
Complexity:
50
Confidence:
90
Support Request:
10
|
needs triage | Regression in Charmcraft 4.2.0 where consecutive charmcraft pack commands fail due to platform state leakage. Ancillary charm incorrectly expects a platform from the previously built charm. Untriaged, no maintainer response. | |
| qwen3.6-35b-a3b-mtp-q6 |
Staleness:
55
Complexity:
60
Confidence:
85
Support Request:
10
|
needs triage | charmcraft pack fails when building multiple charms consecutively with mismatching platforms, incorrectly reusing a managed instance from a previous build. Untriaged, no maintainer response. | |
| qwen3.6-35b-a3b-mtp-q6 |
Staleness:
55
Complexity:
45
Confidence:
90
Support Request:
10
|
needs triage | Consecutive charmcraft pack commands leak platform state between projects, causing subsequent builds to fail with a platform mismatch error. Regression in 4.2.0. Open, unassigned, awaiting triage. |
Update history
| Date | Change |
|---|---|
| updated |
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1104 charmcraft pack on Ubuntu 23.04 (Lunar) fails. | charmcraft | closed | Charmcraft pack failed on Ubuntu 23.04 due to unavailable build environments. PR #1130 addressed the issue but was blocked by an external cloud-images bug. The issue was closed pending upstream resolution. | |
| #2078 `charmcraft clean` does not clean all platforms for charm | charmcraft | open | charmcraft clean only removes LXC containers for platforms currently listed in charmcraft.yaml, leaving stale containers for removed platforms. Reported with repro steps; linked to issue #1338 in Jan 2025, no further activity. |