fix(snap-prepare): make keys optional
Metadata
Current evaluation
Merged. Updates snap-preseed plugin to require only snap-preseed-snaps or snap-preseed-model-assert, making them mutually optional. Sets default validation to enforce. Approved by two reviewers and passed all CI checks.
Suggested action: —
No scores available.
Issue body
This PR:
- makes only one of `snap-preseed-snaps` or `snap-preseed-model-assert` required
- changes default validation to "enforce"
Currently `snap-preseed-snaps` is required for the snap-preseed plugin but the user can provide a model assertion file which would contain a list of snaps.
`snap prepare-image` sets the validation mode to `enforce` by default.
---
- [x] I've followed the [contribution guidelines](https://github.com/canonical/imagecraft/blob/main/CONTRIBUTING.md).
- [x] I've signed the [CLA](http://www.ubuntu.com/legal/contributors/).
- [x] I've successfully run `make lint && make test`.
- [ ] I've added or updated any relevant documentation.
- [ ] In documents I changed, I [added a meta description](https://canonical-starflow.readthedocs-hosted.com/how-to/add-a-page-meta-description/) if one was missing.
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| qwen/qwen3.6-35b-a3b | — | — | Merged. Updates snap-preseed plugin to require only snap-preseed-snaps or snap-preseed-model-assert, making them mutually optional. Sets default validation to enforce. Approved by two reviewers and passed all CI checks. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged a fix for the snap-prepare plugin that makes snap-preseed-snaps and snap-preseed-model-assert optional, requiring only one. Default validation mode is now enforce. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged a fix making snap-preseed-snaps and snap-preseed-model-assert optional, requiring only one. Default validation mode was updated to enforce. Changes passed linting and tests. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #333 docs: add snap-preseed plugin | imagecraft | merged | Merged documentation update adding reference material for the snap-preseed plugin. Approved by two reviewers and passed CI checks. Modified three files with 140 additions and 4 deletions. | |
| #323 Add unit tests for snap-preseed-channel and snap-preseed-validation plugin options | imagecraft | merged | Merged. Unit tests verify snap-preseed-channel and snap-preseed-validation plugin options correctly pass CLI flags to the snap prepare-image command. 32 lines added, zero removed. CI passed. |