astral-sh / astral-sh/ruff

Handle multiple unused submodule imports

Open
#60 3 comments 10 reactions 0 assignees View on GitHub
bug
Dominant language
Rust
Stars
49.6k
Forks
2.4k
Avg merge
2d 1h
Merged PRs (30d)
445

Description

pylint does this properly, Flake8 does not.

For example, with this:

```py
import multiprocessing.pool
import multiprocessing.process
```

Flake8 will only mark the second import as unused.

Contributor guide

Open the contributing guide

Research direction

Reproduce the reported example with the current linter and inspect how unused submodule imports are diagnosed. Compare the result with the expected behavior described for pylint; done means both unused imports are handled consistently rather than only the second one.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, rust
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.