ci: fail Lint when a role declares meta dependencies #246

Open
opened 2026-11-17 17:08:27 +00:00 by Claude · 0 comments
Owner

Spec: Role standard gaps found in review, resolution comment, rule 11. Body narrowed 2026-11-20 by Which issues must land before the first friend: the scenario-selector half already exists on main.

What

A role may depend on another role of this Collection only through ansible.builtin.include_role or import_role with the FQCN mortis.kamino.<role> in its tasks, never through meta/main.yml dependencies.

  • Lint check: fail when any roles/*/meta/main.yml has a non-empty dependencies list. Use a standard tool if one fits (an ansible-lint rule, or a yq one-liner as a pre-commit hook also run in Lint); a script only if neither does.

Already on main, not to rebuild: scripts/select_molecule_scenarios.py selects the scenarios of every role naming mortis.kamino.<changed role>, transitively, with tests. Confirm its tests cover "a diff touching only roles/a/ where roles/b/tasks includes mortis.kamino.a selects both"; add that case only if it is missing.

Not blocked

Shift-left (#187) and the code-style cut (#171) also edit .pre-commit-config.yaml and scripts/. That is a merge to resolve, not a dependency: build this on whatever main holds.

Done when

  • A meta dependency fails Lint, shown by a test.
  • The selector case above is covered by a test (existing or added).
  • No changelog fragment: tooling only.
Spec: [Role standard gaps found in review](https://git.rkdr.net/Mortis/Kamino/issues/214), resolution comment, rule 11. Body narrowed 2026-11-20 by [Which issues must land before the first friend](https://git.rkdr.net/Mortis/Kamino/issues/259): the scenario-selector half already exists on `main`. ## What A role may depend on another role of this Collection only through `ansible.builtin.include_role` or `import_role` with the FQCN `mortis.kamino.<role>` in its tasks, never through `meta/main.yml` `dependencies`. - **Lint check:** fail when any `roles/*/meta/main.yml` has a non-empty `dependencies` list. Use a standard tool if one fits (an ansible-lint rule, or a `yq` one-liner as a pre-commit hook also run in Lint); a script only if neither does. Already on `main`, not to rebuild: `scripts/select_molecule_scenarios.py` selects the scenarios of every role naming `mortis.kamino.<changed role>`, transitively, with tests. Confirm its tests cover "a diff touching only `roles/a/` where `roles/b/tasks` includes `mortis.kamino.a` selects both"; add that case only if it is missing. ## Not blocked Shift-left ([#187](https://git.rkdr.net/Mortis/Kamino/issues/187)) and the code-style cut ([#171](https://git.rkdr.net/Mortis/Kamino/issues/171)) also edit `.pre-commit-config.yaml` and `scripts/`. That is a merge to resolve, not a dependency: build this on whatever `main` holds. ## Done when - A `meta` dependency fails Lint, shown by a test. - The selector case above is covered by a test (existing or added). - No changelog fragment: tooling only.
Claude added this to the Continuous delivery milestone 2026-11-17 17:08:27 +00:00
Claude added the
Status
Ready for Agent
label 2026-11-17 17:08:27 +00:00
Claude added a new dependency 2026-11-17 17:08:33 +00:00
Claude removed a dependency 2026-11-20 21:25:58 +00:00
Claude changed title from ci: keep meta dependencies empty and run a dependent role's scenarios when a role it includes changes to ci: fail Lint when a role declares meta dependencies 2026-11-20 21:26:23 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mortis/Kamino#246