← Back to issue list

Automatically re-stage if dirty.

View original Github issue

Metadata

Project
snapcraft
Number
#443
Type
pull request
State
merged
Author
kyrofa
Labels
Created
Updated
Closed

Current evaluation

Merged PR automatically re-stages and strips Snapcraft steps upon YAML changes, resolving Launchpad bug #1477904. The update modifies six files to detect out-of-date configurations and trigger a clean re-run.

Suggested action:

No scores available.

Issue body

Currently Snapcraft only notices YAML changes for the strip step. For all other steps, if the step has already run it simply says so and bails. This PR makes progress on LP: [#1477904](https://bugs.launchpad.net/snapcraft/+bug/1477904) by changing that for the stage step, where now if one changes the `stage` keyword in the YAML, stage will notice that it's out of date and automatically clean itself (along with the strip step since it depends upon stage) and re-run.

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged PR automatically re-stages and strips Snapcraft steps upon YAML changes, resolving Launchpad bug #1477904. The update modifies six files to detect out-of-date configurations and trigger a clean re-run.
qwen3.6-35b-a3b-mtp-q6 Merged. Snapcraft now automatically detects YAML changes to the stage configuration, cleans the stage and dependent strip steps, and re-runs them. Resolves LP #1477904.
qwen3.6-35b-a3b-mtp-q6 Merged. Snapcraft now automatically detects YAML stage keyword changes, cleans the stage and dependent strip steps, and re-runs them. Resolves Launchpad bug #1477904.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#442 Automatically re-strip if dirty. snapcraft merged Merged. Automatically re-runs the strip step when the snapcraft.yaml snap keyword changes. Detects dirty state via YAML property comparison, cleans, and re-executes. Resolves Launchpad bug #1477904. Documentation added during review.
81%
#2152 many: automatically redo step for specified part snapcraft merged Merged to master, resolving LP: #1774260. Snapcraft now automatically cleans and re-runs a specified part's step instead of skipping it. Approved by one reviewer with 94.63% diff coverage.
72%
#448 Detect dirty pull step. snapcraft merged Merged changes add dirty detection for the pull step in Snapcraft, resolving Launchpad bug #1477904. The update errors on YAML changes, requiring manual cleanup instead of automatic removal. Approved by sergiusens.
72%
#447 Detect dirty build step. snapcraft merged Merged. Adds dirty build step detection to Snapcraft, prompting manual cleanup when YAML changes affect the build step. Addresses LP #1477904. Auto-rebuilds were omitted to prevent wasting time on long builds. Approved by sergiusens.
72%
#1477904 snapcraft.yaml needs to make all stages dirty (was: the can't add file without recreating entire package) snapcraft (launchpad) closed Abandoned. Snapcraft continues to skip stages when files are added, requiring manual cleanup of build directories to trigger rebuilds.
71%
#1663623 Changing stage-packages requires cleaning the pull stage snapcraft (launchpad) closed Closed without resolution. Snapcraft incorrectly requiring a pull stage clean after stage-packages changes was abandoned or superseded by later versions.
71%