Skip to content

excore check: report rule coverage and warn about rules with no effect - #5

Merged
ikeige-coder merged 1 commit into
ikeige-coder:mainfrom
Tet-9:feat/check-rule-coverage
Oct 5, 2026
Merged

ikeige-coder merged 1 commit into
ikeige-coder:mainfrom
Tet-9:feat/check-rule-coverage

Conversation

@Tet-9

@Tet-9 Tet-9 commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Rules are applied in order, so a later rule can silently override everything an earlier one matched. The earlier rule then looks active in the manifest but changes nothing, which is an easy mistake to make when tuning recipes.

excore check now prints how many units stay on the default and warns (stderr, exit code unchanged) for every rule that ends up owning no units. ScreenReport gains rule_units, default_units and unused_rules. Tests cover the counts and the CLI warning.

@Tet-9
Tet-9 requested a review from ikeige-coder as a code owner October 5, 2026 08:32

@ikeige-coder ikeige-coder left a comment •

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merging. This catches rules that silently own no units after later rules override them, which is an easy mistake when tuning recipes. It's a warning only, exit code unchanged, and the tests cover the counts and the CLI output.
Follow-up nit, not blocking: a rule can also own zero units because its match hits nothing (a typo). The warning currently says "later rules override every unit it matches". A reword would actually do, But nevermind.

@ikeige-coder
ikeige-coder merged commit cfde2b2 into ikeige-coder:main Oct 5, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants