From mason
Review chisel slice definition files (SDFs) for canonical/chisel-releases. Covers CI checks, reviewer conventions, style enforcement, dependency validation, formatting rules, forward-port requirements, and common rejection reasons. Use when reviewing a PR, validating an SDF, or checking slice quality before submission.
How this skill is triggered — by the user, by Claude, or both
Slash command
/mason:review-sliceThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Skill for reviewing slices in [`canonical/chisel-releases`](https://github.com/canonical/chisel-releases).
Skill for reviewing slices in canonical/chisel-releases.
Prerequisites: read @./CHISEL.md for chisel/SDF format reference, branch model, schema versions, and canonical naming conventions. This skill focuses on what to check when reviewing.
These automated checks run on every PR. Understand what each one validates:
| Check | Failure means |
|---|---|
lint | YAML syntax/formatting issue in SDF |
install-slices | Slice can't chisel cut, or package not in archive for some arch |
removed-slices | SDF deleted -- breaking unless package is gone from the archive |
forward-port-missing | New slice in branch but not in newer live releases |
pkg-deps | Informational diff of declared deps vs apt depends; non-blocking but reviewer signal |
validate-hints | hint: text fails NLP style check (v3+ only) |
spread | Integration test failed inside LXD test container |
cla-check | CLA unsigned |
All checks must be green before review. pkg-deps is non-blocking but reviewers use it to cross-check dependency accuracy.
Depends: only. Not Recommends: or Suggests:. Including Recommends: is an immediate rejection.apt Depends: should appear as an essential: entry. Cross-check via pkg-deps CI output.postinst invokes another package's tool (e.g. update-mime-database), either drop the dep or write a mutate: equivalent. Do not pull in the tool's package as a dependency.Published slices are append-only in spirit. Removing files from an existing slice is a regression for downstream consumers. If a slimmer variant is needed, create a new slice (core, minimal, or a more specific name) rather than removing from an existing one.
Verify against the Canonical Slice Names table in @./CHISEL.md:
bins (never bin) for executableslibs (never lib) for shared librariesconfig for configuration files; break large configs into <purpose>-configscripts for non-binary executables (not in bins)copyright for deb copyright (mandatory)license / notice for upstream licence/notice (separate from copyright)core for minimum-functional subset (never all -- rejected)<pkg>-core, keep verbatimSlice names must: be lowercase, >= 3 characters, only a-z 0-9 -, start with a letter.
These are hard gates. Reject if violated:
essential: placed at top of file, right after package:.copyright slice placed last in the slices: block.package: matches filename stem. slices/foo.yaml -> package: foo.*-linux-*, not explicit triples. E.g. /usr/lib/*-linux-*/libnghttp2.so.14*:.* for single-version sonames: libfoo.so.1: not libfoo.so.1*:.symlink: if deb ships it. Chisel preserves deb symlinks. Manual symlink: only for paths the deb doesn't ship (e.g. created by maintainer scripts)./usr/bin/dotnet: # Symlink to ../lib/dotnet/dotnet./path: {arch: [amd64, arm64]}.{arch: [amd64, arm64]}{arch: [ amd64, arm64 ]} or {arch: [arm64, amd64]}Check format: in chisel.yaml on the target branch:
hint: is v3+ only. Reject if used on v1/v2 branches.prefer: is v2+ only. Reject if used on v1 branches.v3-essential: (arch-gated deps map) is v3+ only.pro: under archives: is v2+ unified. v1 uses separate v2-archives: block.bins slice must be exercised in spread tests. "Please test every binary being delivered" is a recurring rejection reason.--version alone is insufficient for applications. Test actual functionality.tests/spread/integration/<pkg>/task.yaml.forward-port-missing CI auto-labels PRs that lack this.### Forward porting\nn/a in description.Defer to CONTRIBUTING.md. Key points:
main. PRs into main are wrong.feat:, fix:, test:, ci:, chore:, docs:, refactor:. Subject lowercase, imperative, <=50 chars, no trailing period. Body wrap 72.contents pathscopyright slice or not in global essential:Recommends:/Suggests: included as dependenciesbin/lib instead of bins/libssymlink: for paths the deb already shipsbins slicehint:) used on v1/v2 branchespackage: field doesn't match YAML filename stemGitHub Copilot auto-reviews and proposes patterns that reviewers reject:
{ arch: [ amd64 ] } (wrong): {} on essential entries (wrong for v1/v2)Do not follow Copilot suggestions blindly.
After completing a review, perform a reflection pass to verify your review criteria against the sources of truth and improve this skill for next time.
Fetch the current documentation and compare the review criteria used:
# SDF format reference (field validity, format version rules)
curl -fsSL https://raw.githubusercontent.com/canonical/chisel-docs/main/docs/reference/chisel-releases/slice-definitions.md
# chisel.yaml reference (schema versions, what format gates what)
curl -fsSL https://raw.githubusercontent.com/canonical/chisel-docs/main/docs/reference/chisel-releases/chisel.yaml.md
# Contribution rules
curl -fsSL https://raw.githubusercontent.com/canonical/chisel-releases/main/CONTRIBUTING.md
# Canonical reference SDFs on the target branch
curl -fsSL https://raw.githubusercontent.com/canonical/chisel-releases/<branch>/slices/bash.yaml
curl -fsSL https://raw.githubusercontent.com/canonical/chisel-releases/<branch>/slices/base-files.yaml
Check:
CONTRIBUTING.md added new requirements (e.g. new commit conventions, changed approval process)?If the review flagged something as invalid but chisel cut accepted it (or vice versa), check the tool source:
curl -fsSL https://raw.githubusercontent.com/canonical/chisel/main/internal/setup/setup.go
The tool's actual behaviour overrides any written convention.
If discrepancies were found:
review-slice/SKILL.md)@./CHISEL.mdwrite-slice/SKILL.mdPrinciples:
npx claudepluginhub rockcrafters/mason --plugin masonProvides CDSS development patterns for drug interaction checking, dose validation, clinical scoring (NEWS2, qSOFA), and alert classification integrated into EMR workflows.