← Back to issue list

Pre-existing lint/type-check failures: mypy no-any-return in grubutil.py, pyright reportUnusedImport/reportMatchNotExhaustive/reportArgumentType

View original Github issue

Metadata

Project
imagecraft
Number
#404
Type
issue
State
open
Author
lengau
Labels
Created
Updated
Closed

Current evaluation

Tracks pre-existing mypy and pyright lint/type-check failures on main: no-any-return in grubutil.py, unused import in models/__init__.py, non-exhaustive match in image.py, and argument type errors in tests.

Suggested action: needs triage

Reason: The issue has no labels, no assignee, and zero maintainer comments after 24 days. It is a well-structured bug report with specific file/line references and error messages, but no maintainer has yet acknowledged or prioritized it. The four reported issues are real type-check failures (e.g., non-exhaustive match on PartitionSchema missing HYBRID case in image.py:301-303, unused BaseVolume import in models/__init__.py:27) that should be triaged and fixed.

Impact: 50 Quick Win: 37.5 Staleness: 45 Complexity: 25 Confidence: 85 Support Request: 0

Issue body

🤖 [BEEP BOOP, A BOT WROTE THIS COMMENT - Claude Sonnet 5, GitHub Copilot CLI] While validating [#402](https://github.com/canonical/imagecraft/pull/402) (the starbase merge), CI surfaced lint/type-check failures that are **pre-existing on `main`**, not introduced by that PR. Confirmed via a `git worktree` checkout of the pre-merge commit and running the same tools locally: - `mypy`: `imagecraft/pack/grubutil.py:236: error: Returning Any from function declared to return "int | None" [no-any-return]` - `pyright` (newly run in CI as part of `lint-pyright`, which this repo's `Makefile`/`common.mk` already wired up before the merge): - `imagecraft/models/__init__.py:27:5` — `Import "BaseVolume" is not accessed (reportUnusedImport)` - `imagecraft/services/image.py:261:19` — non-exhaustive `match` over `PartitionSchema.HYBRID` (`reportMatchNotExhaustive`) - `tests/integration/services/test_project.py:47:18` and `:77:18` — `None` passed where `ServiceFactory` expected (`reportArgumentType`) None of these lines were touched by the starbase merge. Filing so they're tracked and fixed independently rather than blocking/confusing future merge PRs.

Evaluation history

Date Model Scores Action Summary
qwen3.6-35b-a3b-mtp-q6
Impact: 50
Quick Win: 37.5
Staleness: 45
Complexity: 25
Confidence: 85
Support Request: 0
needs triage Tracks pre-existing mypy and pyright lint/type-check failures on main: no-any-return in grubutil.py, unused import in models/__init__.py, non-exhaustive match in image.py, and argument type errors in tests.
qwen/qwen3.6-35b-a3b
Staleness: 0
Complexity: 20
Confidence: 95
Support Request: 0
needs triage Pre-existing mypy and pyright lint/type-check failures in grubutil.py, models/__init__.py, services/image.py, and test_project.py. Currently unlabelled and awaiting maintainer triage.

Update history

Date Change
created

Related issues

No related issues found above the similarity threshold.