← Back to issue list

fix(reactive): don't overwrite config.yaml from a reactive charm

View original Github issue

Metadata

Project
charmcraft
Number
#2245
Type
pull request
State
merged
Author
lengau
Labels
—
Created
Updated
Closed

Current evaluation

Merged PR #2245 (commit aa28f0dc, CRAFT-4206) stops the package service from overwriting a config.yaml generated by a reactive charm, fixing #2194.

Resolution: closed resolved

Reason: PR #2245 by lengau was merged with 3 approvals and landed as commit aa28f0dc, adding a reactive check in write_metadata() that skips writing config.yaml when the stage dir already contains one. It closes issue #2194.

Evaluated by: mr-cal-bot

No scores available.

Issue body

Fixes #2194 CRAFT-4206

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged PR #2245 (commit aa28f0dc, CRAFT-4206) stops the package service from overwriting a config.yaml generated by a reactive charm, fixing #2194.
stealth/space-bunny-alpha — closed resolved Merged Charmcraft PR #2245 (aa28f0dc) to prevent reactive charms from overwriting config.yaml, fixing #2194.
stealth/space-bunny-alpha — closed resolved Merged PR #2245 (commit aa28f0dc), fixing #2194 and CRAFT-4206 by preventing reactive charms from overwriting config.yaml.
qwen/qwen3.6-35b-a3b — — Merged following approval by three reviewers. Resolves issue #2194 and CRAFT-4206 by preventing reactive charms from overwriting config.yaml. Changes affect three files with minor code adjustments.
qwen3.6-35b-a3b-mtp-q6 — — Merged fix preventing config.yaml overwrites in reactive charms. Resolves issue #2194 and CRAFT-4206 by preserving existing configuration files during charm operations.

Update history

No update history recorded yet.

Related work

  • Related To: charmcraft#2194 (confidence 95%)

    Bug report of reactive builds producing a different config option (e.g. losing snapd_refresh), resolved by this PR.

  • Duplicate Of: charmcraft#1829 (confidence 70%)

    Prior commit 4a3cbacb applied the identical guard for actions.yaml in reactive charms; #2245 mirrors that pattern for config.yaml.

  • Related To: charmcraft#1666 (confidence 55%)

    Commit b2b127e6 'only keep metadata.yaml for reactive charms' is part of the same reactive-metadata mediation effort.

Related issues

Issue Project State Summary Similarity
#1829 fix(reactive): don't overwrite actions.yaml for reactive charms charmcraft merged Merged #1829 as commit 4a3cbacb, fixing #1816 by preserving reactive charms' existing actions.yaml instead of overwriting it.
80%
#1666 fix: only keep metadata.yaml for reactive charms charmcraft merged Merged #1666 (b2b127e6), retaining metadata.yaml only for reactive charms so non-reactive repacks no longer carry stale integration metadata; fixes #1654.
76%
#2194 Builds of charm using reactive plugin produces different config option charmcraft closed Fixed by merged PR #2245 (commit aa28f0dc): reactive-generated config.yaml is no longer overwritten, preserving options such as snapd_refresh.
73%
#1151 build: do not create metafiles when using reactive charmcraft merged Merged #1151 as commit 35adadf4, stopping Charmcraft from generating metafiles for reactive builds and preserving Reactive's own format; fixes #1150.
71%
#777 Do not modify the charm's project when packing using the reactive plugin (CRAFT-928). charmcraft merged Merged PR #777 (CRAFT-928) via commit bac1d03b, preventing reactive packing from modifying the charm project and fixing #693's incorrect dirty versions.
70%