Support component hooks
Metadata
Current evaluation
Component hooks were implemented by merged PRs #4703, #4717 and #4722, adding hook metadata and core24/core22 packaging support.
Resolution: closed resolved
Reason: Merged PR #4703 (commit aa49b3b72) added component-hook metadata. Follow-up PRs #4717 (aafbe672b) and #4722 (9a5dbfa69) added packaging for core24 and core22.
Evaluated by: mr-cal-bot
No scores available.
Issue body
### What needs to get done
### `snapcraft.yaml` syntax
Support the following syntax:
```yaml
components:
<component-name>:
hooks:
<hook-name>:
plugs:
- <plug-name>
<all-currently-valid-hooks>
```
Supported hooks are:
- install
- pre-refresh
- post-refresh
- remove
### `meta/snap.yaml` syntax
The `meta/snap.yaml` needs to list all component metadata, including the component hooks. Currently, this is not happening.
### Why it needs to get done
To support component hooks
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Component hooks were implemented by merged PRs #4703, #4717 and #4722, adding hook metadata and core24/core22 packaging support. | |
| stealth/space-bunny-alpha | — | closed resolved | Component hooks shipped in PRs #4703, #4717, and #4722, adding hook metadata and core24/core22 packaging support. | |
| stealth/space-bunny-alpha | — | closed resolved | Component hooks were implemented in merged PRs #4703, #4717, and #4722, adding hook metadata and core24/core22 packaging support. | |
| stealth/space-bunny-alpha | — | closed resolved | Component hooks were implemented in merged PRs #4703, #4717 and #4722, adding hook metadata and core24/core22 packaging support. | |
| qwen/qwen3.6-35b-a3b | — | — | Deferred pending specification via ST110. Component hooks were not implemented. Maintainers confirmed the feature will be spec'd in the current pulse and implemented later, closing the issue as a roadmap tracking item. | |
| qwen/qwen3.6-35b-a3b | — | — | Deferred pending specification in ST110. Component hook support remains unimplemented, with implementation scheduled for a subsequent development cycle. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed pending specification. Maintainer confirmed component hook support will be detailed in ST110 and implemented in a subsequent pulse. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Deferred pending specification via ST110. Component hook support for snapcraft.yaml and meta/snap.yaml is scheduled for implementation in a subsequent pulse. The request remains closed awaiting future development. |
Update history
No update history recorded yet.
Related work
-
Likely Fixed By:
canonical/snapcraft#4703
(confidence 99%)
Merged metadata support for component hooks.
-
Likely Fixed By:
canonical/snapcraft#4717
(confidence 99%)
Merged component-hook packaging support for core24.
-
Likely Fixed By:
canonical/snapcraft#4722
(confidence 99%)
Merged component-hook packaging support for core22.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #4722 feat: package component hooks for core22 | snapcraft | merged | Merged PR #4722 as commit 9a5dbfa69, enabling component-hook packaging for core22 with the implementation from #4717. | |
| #4703 feat: add component metadata for hooks | snapcraft | merged | Merged PR #4703 (commit aa49b3b72, CRAFT-2463) adding component hook metadata: project definition plus output into the component's meta/component.yaml. Built on merged #4701; follow-ups #4717/#4722 added core24/core22 component hook packaging, closing #4570. | |
| #4717 feat: package component hooks for core24 | snapcraft | merged | Merged PR #4717 as commit aafbe672b, adding core24 component-hook packaging and test coverage for CRAFT-2540. | |
| #1026 Add support for hooks. | snapcraft | merged | PR #1026 merged as commit 01880ee8d ('core: add support for hooks'), adding hook support: executables in snap/hooks/ are copied into the snap, and parts can install hooks into snap/hooks/. Docs followed in #1042 (10c58b652). |