← Back to issue list

Use Craft Application's Linter Service

View original Github issue

Metadata

Project
charmcraft
Number
#2546
Type
issue
State
open
Author
mr-cal
Labels
Status: Triaged Type: Refactor
Created
Updated
Closed
—

Current evaluation

Charmcraft’s triaged refactor to adopt Craft Application’s merged LinterService remains open; 11 custom checkers still run through Charmcraft’s AnalysisService.

Suggested action: keep open

Reason: The refactor remains valid: Charmcraft still has 11 checker classes executed by its own AnalysisService and no LinterService usage, while the requested upstream framework was merged in craft-application#907 at commit a76bcaa6. Port the checkers and update analyze, package, ignore-config, output, and test paths while preserving existing behavior.

Evaluated by: mr-cal-bot

Impact: 48 Quick Win: 15 Complexity: 62 Confidence: 95 Actionability: 84

Issue body

### Check existing issues - [x] I've verified that this request isn't described by any existing issues. ### Request Migrate to the Linter Service as implemented at https://github.com/canonical/craft-application/issues/782 * All linters are implementations of the Craft Application class * The lint command uses the LinterService * Any other uses of linters use the LinterService ### The problem it solves Snapcraft and Charmcraft lint snaps and charms respectively at the end of the lifecycle. These linters don’t share common code and don’t have a similar UX. Additionally, there isn’t a way to add linters to other *craft apps without significant code duplication. Supersedes #2315

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha
Impact: 48
Quick Win: 15
Complexity: 62
Confidence: 95
Actionability: 84
keep open Charmcraft’s triaged refactor to adopt Craft Application’s merged LinterService remains open; 11 custom checkers still run through Charmcraft’s AnalysisService.
qwen/qwen3.6-35b-a3b
Impact: 70
Quick Win: 22
Complexity: 60
Confidence: 80
Actionability: 80
keep open Refactor to migrate charmcraft's linters to the Craft Application LinterService. The upstream framework (craft-application#907) is merged, but charmcraft still uses its own linters.py implementation.
qwen/qwen3.8-27b
Impact: 45
Quick Win: 11
Staleness: 60
Complexity: 75
Confidence: 82
Support Request: 0
keep open Refactor to migrate charmcraft's linters to craft-application's shared LinterService for consistent lint UX across craft apps. Triaged and open; upstream framework (craft-application#907) is merged, but no code changes yet and no human activity for ~7 months.
qwen/qwen3.6-35b-a3b
Staleness: 65
Complexity: 60
Confidence: 85
Support Request: 0
keep open Refactor to migrate snapcraft and charmcraft linting to the shared Craft Application Linter Service. Triaged and open, but inactive for 181 days with only automated Jira sync comments.
qwen3.6-35b-a3b-mtp-q6
Staleness: 65
Complexity: 55
Confidence: 80
Support Request: 5
keep open Refactor to migrate linting to Craft Application's LinterService, addressing code duplication and UX inconsistencies across *craft tools. Currently triaged but inactive for 167 days with only bot comments.
qwen3.6-35b-a3b-mtp-q6
Staleness: 65
Complexity: 70
Confidence: 85
Support Request: 5
keep open Refactor to migrate snapcraft and charmcraft linters to the shared Craft Application LinterService. Currently triaged and awaiting implementation, with no maintainer activity in over five months.

Update history

No update history recorded yet.

Related work

  • Related To: charmcraft#2315 (confidence 100%)

    The issue body explicitly supersedes #2315, which closed without implementing the migration.

  • Related To: craft-application#782 (confidence 100%)

    Named prerequisite; its LinterService was delivered by merged PR #907.

  • Related To: craft-application#907 (confidence 99%)

    Merged implementation of LinterService at commit a76bcaa6, enabling this downstream refactor.

  • Related To: snapcraft#5971 (confidence 91%)

    Open parallel downstream migration that can coordinate shared linter UX and integration work.

Related issues

Issue Project State Summary Similarity
#2315 Use Craft Application's Linter Service charmcraft closed LinterService bounty closed without implementation; craft-application#907 delivered the shared service, and Charmcraft migration was retriaged as canonical/charmcraft#2546.
88%
#5971 Use Craft Application's Linter Service snapcraft open Triaged refactor to replace Snapcraft's bespoke linter runner and reporting with Craft Application's LinterService; the prerequisite is merged, but migration remains unimplemented.
84%
#5542 Use Craft Application's Linter Service snapcraft closed Closed by mr-cal (2026-01-21) as a bounty with no implementation. craft-application#907 (commit a76bcaa6) merged the shared Linter Service, and the migration work was moved to charmcraft#2546, still open.
83%
#141 Add a basic linter service craft-application closed Implemented the extensible linter framework in craft-application by merging PR #907 (commit a76bcaa6), providing shared linter registration and execution for downstream apps.
73%