← Back to issue list

Add `plugs` and `slots` keys to the project model

View original Github issue

Metadata

Project
snapcraft
Number
#5168
Type
issue
State
open
Author
mr-cal
Labels
Status: Triaged Type: Enhancement
Created
Updated
Closed
—

Current evaluation

Triaged enhancement to add typed top-level plug and slot declarations for early project validation; app-level lists are modeled, and #5172's invalid-YAML failure was folded into this open enhancement.

Suggested action: keep open

Reason: The issue is explicitly marked Triaged and Enhancement and was authored by a maintainer; #5172 confirms malformed interface YAML can pack successfully and fail only during upload. The desired early validation is clear, but implementing models for many interface-specific plug and slot fields is substantial, and no resolving change is identified.

Evaluated by: mr-cal-bot

Impact: 45 Quick Win: 11 Complexity: 67 Confidence: 88 Actionability: 76

Issue body

### What needs to get done The `plugs` and `slots` keys have many keys. A few `plug` keys exist but no `slots` keys are documented or defined in [the project model](https://github.com/canonical/snapcraft/blob/5317dbebac1c953192ff38e4c6fddd294f979cb1/snapcraft/models/project.py#L628). ### Why it needs to get done Faster iteration for developers - errors should be raised early on when validating the model. This has been reported in https://github.com/canonical/snapcraft/issues/5172

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha
Impact: 45
Quick Win: 11
Complexity: 67
Confidence: 88
Actionability: 76
keep open Triaged enhancement to add typed top-level plug and slot declarations for early project validation; app-level lists are modeled, and #5172's invalid-YAML failure was folded into this open enhancement.
qwen/qwen3.6-35b-a3b
Impact: 35
Quick Win: 21
Complexity: 25
Confidence: 85
Actionability: 80
keep open Enhancement to add `plugs` key to the Project model for early validation. `slots` already exists at line 1767, but `plugs` is only defined in the App model, not at the project level despite being used in many snapcraft.yaml examples.
qwen/qwen3.8-27b
Impact: 40
Quick Win: 24
Staleness: 55
Complexity: 40
Confidence: 70
Support Request: 10
keep open Request to add plugs and slots keys to the project model for early validation. The slots key is now defined in project.py with a validator, so the core ask appears addressed.
qwen/qwen3.6-35b-a3b
Staleness: 90
Complexity: 40
Confidence: 85
Support Request: 10
close stale Enhancement to add plugs and slots keys to the project model for early validation. Triaged but inactive for over a year with no maintainer traction or recent updates.
qwen3.6-35b-a3b-mtp-q6
Staleness: 85
Complexity: 30
Confidence: 80
Support Request: 10
keep open Enhancement to add plugs and slots keys to the project model for early validation. Triaged by a maintainer but inactive for over a year.

Update history

No update history recorded yet.

Related work

  • Related To: canonical/snapcraft#5172 (confidence 99%)

    #5172 was closed as a duplicate of #5168 after its scope was expanded to validate plugs and slots.

Related issues

No related issues found above the similarity threshold.