← Back to issue list

[3.9-backport] meta: ensure Snap's `assumes` is initialized as a set

View original Github issue

Metadata

Project
snapcraft
Number
#2879
Type
pull request
State
merged
Author
cjp256
Labels
Created
Updated
Closed

Current evaluation

Merged backport to 3.9 resolving SNAPCRAFT-16C. Converts the assumes property from a list to a set during config initialization to prevent command-chain exceptions. Includes regression test coverage.

Suggested action:

No scores available.

Issue body

When reading the config data dictionary, convert the list to a set. The `assumes` property is defined as a set in Snap meta, but derives from a list in the the snap meta. This causes an exception when using `command-chain`, but `command-chain` is not already in the `assumes` (due to the use of Snap's usage of `.add()` on the set, which is not available for lists). Add a test for coverage/verification. Fixes SNAPCRAFT-16C Signed-off-by: Chris Patterson <chris.patterson@canonical.com> - [ ] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [ ] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [ ] Have you successfully run `./runtests.sh static`? - [ ] Have you successfully run `./runtests.sh tests/unit`? -----

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged backport to 3.9 resolving SNAPCRAFT-16C. Converts the assumes property from a list to a set during config initialization to prevent command-chain exceptions. Includes regression test coverage.
qwen3.6-35b-a3b-mtp-q6 Merged a 3.9 backport fixing SNAPCRAFT-16C by converting the assumes property from a list to a set during config parsing. This prevents command-chain exceptions and includes a verification test.
qwen3.6-35b-a3b-mtp-q6 Merged a 3.9 backport that fixes SNAPCRAFT-16C by converting the assumes meta property from a list to a set during config parsing. This prevents command-chain exceptions and adds unit test coverage.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#2796 meta: ensure Snap's `assumes` is initialized as a set snapcraft merged Merged fix for SNAPCRAFT-16C that converts the assumes configuration from a list to a set during initialization. This resolves a runtime exception when using command-chain by ensuring the add method functions correctly. Includes updated unit tests.
92%