← Back to issue list

plugins: improve python and go schema validation

View original Github issue

Metadata

Project
snapcraft
Number
#2473
Type
pull request
State
merged
Author
cmatsuoka
Labels
—
Created
Updated
Closed

Current evaluation

Merged as 3f7d63cdf: tightened Go and Python plugin schemas and added validation tests; the proposed pre-build provider validation call was removed during review.

Resolution: closed resolved

Reason: PR #2473 merged as commit 3f7d63cdf, landing the Go and Python schema and test changes. The earlier provider invocation-validation logic was deliberately removed before merge.

Evaluated by: mr-cal-bot

No scores available.

Issue body

When using build providers, validate our yaml file schema prior to executing ourselves inside the provider instance. This allows us to quickly interrupt execution if validation fails. Also added extra validation entries to the Go and Python plugins, to require either sources or packages and prevent crashes in the test case listed in the original bug report. LP: #1806055 Signed-off-by: Claudio Matsuoka <claudio.matsuoka@canonical.com> - [x] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [x] If this is a bugfix. Have you checked that there is a bug report open for the issue you are trying to fix on [bug reports](https://bugs.launchpad.net/snapcraft)? - [ ] If this is a new feature. Have you discussed the design on the [forum](https://forum.snapcraft.io)? - [x] Have you successfully run `./runtests.sh static`? - [x] Have you successfully run `./runtests.sh tests/unit`? -----

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged as 3f7d63cdf: tightened Go and Python plugin schemas and added validation tests; the proposed pre-build provider validation call was removed during review.
stealth/space-bunny-alpha — closed resolved Merged in #2473 (3f7d63cdf): tightened Go and Python plugin schemas and added tests. The proposed pre-build schema-validation call was removed during review.
qwen/qwen3.6-35b-a3b — — Merged Python and Go plugin schema validation improvements requiring either sources or packages to prevent crashes. Final changes kept schema constraints but removed the pre-execution validation call per review. Resolves LP: #1806055.
qwen3.6-35b-a3b-mtp-q6 — — Merged. Improved Python and Go plugin schema validation with tests enforcing source and package requirements to prevent crashes. Pre-execution logic was dropped, keeping only schema updates. Fixes LP: #1806055.

Update history

No update history recorded yet.

Related work

  • Related To: launchpad#1806055 (confidence 99%)

    The PR body cites this LaunchPad bug as the original schema-validation report.

Related issues

No related issues found above the similarity threshold.