mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-08-01 21:50:21 +08:00
Enable Ruff PLW (Pylint Warning) (#13749)
This commit is contained in:
+6
-4
@@ -53,9 +53,7 @@ select = [
|
||||
"I", # isort
|
||||
"N", # pep8-naming
|
||||
"PGH", # pygrep-hooks
|
||||
"PLC", # Pylint Convention
|
||||
"PLE", # Pylint Error
|
||||
"PLR", # Pylint Refactor
|
||||
"PL", # Pylint
|
||||
"RUF", # Ruff-specific and unused-noqa
|
||||
"TRY", # tryceratops
|
||||
"UP", # pyupgrade
|
||||
@@ -186,15 +184,19 @@ ignore = [
|
||||
# Rules that are out of the control of stub authors:
|
||||
###
|
||||
# Names in stubs should match the implementation, even if it's ambiguous.
|
||||
# https://github.com/astral-sh/ruff/issues/15293
|
||||
"A", # flake8-builtins
|
||||
"F403", # `from . import *` used; unable to detect undefined names
|
||||
# Stubs can sometimes re-export entire modules.
|
||||
# Issues with using a star-imported name will be caught by type-checkers.
|
||||
"F403", # `from . import *` used; unable to detect undefined names
|
||||
"F405", # may be undefined, or defined from star imports
|
||||
# Most pep8-naming rules don't apply for third-party stubs like typeshed.
|
||||
# N811 to N814 could apply, but we often use them to disambiguate a name whilst making it look like a more common one
|
||||
"N8", # pep8-naming
|
||||
# Stubs are allowed to use private variables (pyright's reportPrivateUsage is also disabled)
|
||||
"PLC2701", # Private name import from external module
|
||||
# Names in stubs should match implementation
|
||||
"PLW0211", # First argument of a static method should not be named `{argument_name}`
|
||||
]
|
||||
"lib/ts_utils/**" = [
|
||||
# Doesn't affect stubs. The only re-exports we have should be in our local lib ts_utils
|
||||
|
||||
Reference in New Issue
Block a user