← Back to issue list

feat: add linter checks for naming conventions

View original Github issue

Metadata

Project
charmcraft
Number
#1487
Type
pull request
State
merged
Author
deusebio
Labels
—
Created
Updated
Closed

Current evaluation

Merged PR #1487 as commit 01661572, adding linter checks that recommend hyphens over snake_case for composite configuration and action keys.

Resolution: closed resolved

Reason: PR #1487 was merged into main as commit 01661572, delivering the requested naming-convention linter checks.

Evaluated by: mr-cal-bot

No scores available.

Issue body

This PR provides extra checks for compliance of configuration options, action names and action parameters with respect to use hyphens instead of snake case when composite/compound keys are used. The checks follows [this guideline](https://juju.is/docs/sdk/styleguide#heading--naming). In general, we raise warning, although I believe that charms should provide strong consistency on the naming scheme adopted within the charm. So if one uses mixed contentions (some keys have hyphens and others have snake case), I would believe it is fair to error out. This could be by passed by using `--force`, but that would produce a strong nudge on charmers to NOT mix the two conventions.

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged PR #1487 as commit 01661572, adding linter checks that recommend hyphens over snake_case for composite configuration and action keys.
stealth/space-bunny-alpha — closed resolved Merged as commit 01661572, adding lint warnings for snake_case config options, actions, and parameters, including mixed hyphen/underscore naming.
stealth/space-bunny-alpha — closed resolved Merged #1487 as commit 01661572, adding linter warnings for snake_case and mixed naming in config, action, and action-parameter keys.
stealth/space-bunny-alpha — closed resolved Merged PR #1487 as commit 01661572, adding linter checks that prefer hyphens over snake_case for composite configuration and action keys.
stealth/space-bunny-alpha — closed resolved Merged into imagecraft: added linter checks favoring hyphens over snake case in compound configuration, action-name, and action-parameter keys.
stealth/space-bunny-alpha — closed resolved Merged PR #1487 (commit 01661572), adding linter checks to prefer hyphens over snake_case for composite configuration and action keys.
qwen/qwen3.6-35b-a3b — — Merged PR adding linter checks to enforce hyphen-based naming for composite keys per the Juju SDK styleguide. Approved by two reviewers, refactored into a centralized Linter class, and merged with 240 lines added.
qwen3.6-35b-a3b-mtp-q6 — — Merged PR adding linter checks to enforce hyphen-based naming for Juju charm configs and actions per SDK guidelines. Refactored into a dedicated Linter class with a --force bypass for mixed conventions. CI tests passed after retrigger.

Update history

No update history recorded yet.

Related issues

No related issues found above the similarity threshold.