Skip to content

Commit

Permalink
Fix: Implement additional fixes from ruff that somehow went unnoticed
Browse files Browse the repository at this point in the history
  • Loading branch information
AvlWx2014 committed Sep 26, 2024
1 parent 34d4cb0 commit 8bd49d0
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 12 deletions.
14 changes: 8 additions & 6 deletions src/collektions/_iterable.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,20 @@
"windowed",
]

from collections.abc import Generator
from contextlib import suppress
from numbers import Real
from typing import (
Any,
Callable,
from collections.abc import (
Collection,
Generator,
Hashable,
Iterable,
Mapping,
MutableMapping,
Sequence,
)
from contextlib import suppress
from numbers import Real
from typing import (
Any,
Callable,
overload,
)

Expand Down
4 changes: 2 additions & 2 deletions src/collektions/_mapping.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"map_values_to",
]

from collections.abc import MutableMapping
from typing import Callable, Iterable, Mapping, MutableSequence
from collections.abc import Iterable, Mapping, MutableMapping, MutableSequence
from typing import Callable

from ._types import K, R, V

Expand Down
3 changes: 2 additions & 1 deletion src/collektions/_sequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"take_last_while",
]

from typing import Callable, Sequence
from collections.abc import Sequence
from typing import Callable

from ._defaults import default_predicate
from ._types import R, T
Expand Down
3 changes: 2 additions & 1 deletion src/collektions/shadow.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
all_of_them = all(iterable, predicate)
"""

from typing import Callable, Iterable
from collections.abc import Iterable
from typing import Callable

from ._types import R, T

Expand Down
4 changes: 2 additions & 2 deletions tests/test__iterable.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

import string
from collections import namedtuple
from collections.abc import Collection, Sized
from collections.abc import Collection, Hashable, Iterable, Sized
from math import isnan
from numbers import Real
from string import ascii_lowercase
from typing import Callable, Hashable, Iterable, NamedTuple, TypeVar
from typing import Callable, NamedTuple, TypeVar

import pytest
from hamcrest import (
Expand Down

0 comments on commit 8bd49d0

Please sign in to comment.