Skip to content

Commit

Permalink
chore(ruff) Automated fixes for typing annotations
Browse files Browse the repository at this point in the history
Fixed 6 errors:
- src/libtmux/_vendor/version.py:
    1 × I001 (unsorted-imports)
    1 × UP006 (non-pep585-annotation)
- src/libtmux/test.py:
    2 × I001 (unsorted-imports)
    1 × UP006 (non-pep585-annotation)
    1 × TC003 (typing-only-standard-library-import)

Found 1374 errors (6 fixed, 1368 remaining).
44 files left unchanged

uv run ruff check --select ALL . --fix --unsafe-fixes --preview --show-fixes; uv run ruff format .
  • Loading branch information
tony committed Jan 4, 2025
1 parent bb13d70 commit b76c353
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/libtmux/_vendor/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import itertools
import re
import typing as t
from collections.abc import Callable

from ._structures import Infinity, InfinityType, NegativeInfinity, NegativeInfinityType

Expand Down Expand Up @@ -42,7 +43,7 @@
PrePostDevType,
LocalType,
]
VersionComparisonMethod = t.Callable[[CmpKey, CmpKey], bool]
VersionComparisonMethod = Callable[[CmpKey, CmpKey], bool]

_Version = collections.namedtuple(
"_Version",
Expand Down
4 changes: 2 additions & 2 deletions src/libtmux/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

if t.TYPE_CHECKING:
import types
from collections.abc import Generator
from collections.abc import Callable, Generator

from libtmux.server import Server
from libtmux.session import Session
Expand Down Expand Up @@ -64,7 +64,7 @@ def __next__(self) -> str:


def retry_until(
fun: t.Callable[[], bool],
fun: Callable[[], bool],
seconds: float = RETRY_TIMEOUT_SECONDS,
*,
interval: float = RETRY_INTERVAL_SECONDS,
Expand Down

0 comments on commit b76c353

Please sign in to comment.