summaryrefslogtreecommitdiff
path: root/pylint/utils/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'pylint/utils/utils.py')
-rw-r--r--pylint/utils/utils.py19
1 files changed, 18 insertions, 1 deletions
diff --git a/pylint/utils/utils.py b/pylint/utils/utils.py
index 96f8a6acc..6c9f11298 100644
--- a/pylint/utils/utils.py
+++ b/pylint/utils/utils.py
@@ -56,16 +56,24 @@ GLOBAL_OPTION_LIST = Literal["ignored-modules"]
GLOBAL_OPTION_PATTERN = Literal[
"no-docstring-rgx", "dummy-variables-rgx", "ignored-argument-names"
]
+GLOBAL_OPTION_PATTERN_LIST = Literal["ignore-paths"]
GLOBAL_OPTION_TUPLE_INT = Literal["py-version"]
GLOBAL_OPTION_NAMES = Union[
GLOBAL_OPTION_BOOL,
GLOBAL_OPTION_INT,
GLOBAL_OPTION_LIST,
GLOBAL_OPTION_PATTERN,
+ GLOBAL_OPTION_PATTERN_LIST,
GLOBAL_OPTION_TUPLE_INT,
]
T_GlobalOptionReturnTypes = TypeVar(
- "T_GlobalOptionReturnTypes", bool, int, List[str], Pattern[str], Tuple[int, ...]
+ "T_GlobalOptionReturnTypes",
+ bool,
+ int,
+ List[str],
+ Pattern[str],
+ List[Pattern[str]],
+ Tuple[int, ...],
)
@@ -223,6 +231,15 @@ def get_global_option(
@overload
def get_global_option(
checker: "BaseChecker",
+ option: GLOBAL_OPTION_PATTERN_LIST,
+ default: Optional[List[Pattern[str]]] = None,
+) -> List[Pattern[str]]:
+ ...
+
+
+@overload
+def get_global_option(
+ checker: "BaseChecker",
option: GLOBAL_OPTION_TUPLE_INT,
default: Optional[Tuple[int, ...]] = None,
) -> Tuple[int, ...]: