|
23 | 23 | import os |
24 | 24 | import subprocess |
25 | 25 | import sys |
26 | | -from typing import Any, Dict, Final, List, Sequence |
| 26 | +from typing import Any, Dict, Final, Iterable, List, Sequence |
27 | 27 |
|
28 | 28 |
|
29 | 29 | class LintArgs: |
@@ -194,7 +194,7 @@ def filter_changed_files(self, changed_files: Sequence[str]) -> Sequence[str]: |
194 | 194 | arg for arg in changed_files if "third-party" not in arg |
195 | 195 | ] |
196 | 196 |
|
197 | | - filtered_files = [] |
| 197 | + filtered_files: List[str] = [] |
198 | 198 | for filepath in clang_tidy_changed_files: |
199 | 199 | _, ext = os.path.splitext(filepath) |
200 | 200 | if ext not in (".c", ".cpp", ".cxx", ".h", ".hpp", ".hxx"): |
@@ -298,8 +298,8 @@ class Doc8LintHelper(LintHelper): |
298 | 298 | def instructions(self, files_to_lint: Iterable[str], args: LintArgs) -> str: |
299 | 299 | return f"doc8 -q {' '.join(files_to_lint)}" |
300 | 300 |
|
301 | | - def filter_changed_files(self, changed_files: Iterable[str]) -> Sequence[str]: |
302 | | - filtered_files = [] |
| 301 | + def filter_changed_files(self, changed_files: Sequence[str]) -> Sequence[str]: |
| 302 | + filtered_files: List[str] = [] |
303 | 303 | for filepath in changed_files: |
304 | 304 | _, ext = os.path.splitext(filepath) |
305 | 305 | if ext != ".rst": |
|
0 commit comments