mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-05-15 05:30:33 +00:00
Remove unused Sequence imports after argv type change
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
e514e01ee5
commit
125cb6f78c
24 changed files with 24 additions and 24 deletions
|
|
@ -5,7 +5,7 @@ import ast
|
||||||
import platform
|
import platform
|
||||||
import sys
|
import sys
|
||||||
import traceback
|
import traceback
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import ast
|
import ast
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import NamedTuple
|
from typing import NamedTuple
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ from __future__ import annotations
|
||||||
import argparse
|
import argparse
|
||||||
import io
|
import io
|
||||||
import tokenize
|
import tokenize
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from tokenize import tokenize as tokenize_tokenize
|
from tokenize import tokenize as tokenize_tokenize
|
||||||
|
|
||||||
NON_CODE_TOKENS = frozenset((
|
NON_CODE_TOKENS = frozenset((
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import json
|
import json
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import Any
|
from typing import Any
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os.path
|
import os.path
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
from pre_commit_hooks.util import cmd_output
|
from pre_commit_hooks.util import cmd_output
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os.path
|
import os.path
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import sys
|
import sys
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
if sys.version_info >= (3, 11): # pragma: >=3.11 cover
|
if sys.version_info >= (3, 11): # pragma: >=3.11 cover
|
||||||
import tomllib
|
import tomllib
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ from __future__ import annotations
|
||||||
import argparse
|
import argparse
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from re import Pattern
|
from re import Pattern
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import xml.sax.handler
|
import xml.sax.handler
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
from collections.abc import Generator
|
from collections.abc import Generator
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from typing import NamedTuple
|
from typing import NamedTuple
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ from __future__ import annotations
|
||||||
import argparse
|
import argparse
|
||||||
import ast
|
import ast
|
||||||
import traceback
|
import traceback
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import NamedTuple
|
from typing import NamedTuple
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
BLACKLIST = [
|
BLACKLIST = [
|
||||||
b'BEGIN RSA PRIVATE KEY',
|
b'BEGIN RSA PRIVATE KEY',
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os
|
import os
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import IO
|
from typing import IO
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ from __future__ import annotations
|
||||||
import argparse
|
import argparse
|
||||||
from collections.abc import Callable
|
from collections.abc import Callable
|
||||||
from collections.abc import Iterable
|
from collections.abc import Iterable
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import Any
|
from typing import Any
|
||||||
from typing import IO
|
from typing import IO
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os
|
import os
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
from pre_commit_hooks.util import cmd_output
|
from pre_commit_hooks.util import cmd_output
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import collections
|
import collections
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
CRLF = b'\r\n'
|
CRLF = b'\r\n'
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import re
|
import re
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import AbstractSet
|
from typing import AbstractSet
|
||||||
|
|
||||||
from pre_commit_hooks.util import CalledProcessError
|
from pre_commit_hooks.util import CalledProcessError
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import re
|
import re
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
from typing import IO
|
from typing import IO
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ complicated YAML files.
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
QUOTES = ["'", '"']
|
QUOTES = ["'", '"']
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import io
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
import tokenize
|
import tokenize
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
if sys.version_info >= (3, 12): # pragma: >=3.12 cover
|
if sys.version_info >= (3, 12): # pragma: >=3.12 cover
|
||||||
FSTRING_START = tokenize.FSTRING_START
|
FSTRING_START = tokenize.FSTRING_START
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ from __future__ import annotations
|
||||||
import argparse
|
import argparse
|
||||||
import os.path
|
import os.path
|
||||||
import re
|
import re
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def main(argv: Iterable[str] | None = None) -> int:
|
def main(argv: Iterable[str] | None = None) -> int:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from __future__ import annotations
|
||||||
|
|
||||||
import argparse
|
import argparse
|
||||||
import os
|
import os
|
||||||
from collections.abc import Iterable, Sequence
|
from collections.abc import Iterable
|
||||||
|
|
||||||
|
|
||||||
def _fix_file(
|
def _fix_file(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue