Closed
Description
See #376 (comment).
Right now eachdist.py
generates a long pylint
command that lints the entire project in one run, which raises false errors (especially no-member
errors) if two modules import different classes or modules with the same local name.
It's easy to fix this by linting each file separately, which eachdist.py
already supports:
diff --git a/scripts/eachdist.py b/scripts/eachdist.py
index 8d41315f..c23e8853 100755
--- a/scripts/eachdist.py
+++ b/scripts/eachdist.py
@@ -478,9 +478,7 @@ def lint_args(args):
)
runsubprocess(args.dry_run, ("flake8", rootdir), check=True)
execute_args(
- parse_subargs(
- args, ("exec", "pylint {}", "--all", "--mode", "lintroots",),
- )
+ parse_subargs(args, ("exec", "pylint {}", "--mode", "lintroots",),)
)
But this makes lint significantly slower. A better solution might be to lint each package separately, or lint all files separately in parallel.