Skip to content

Commit

Permalink
Fixed pyright tests
Browse files Browse the repository at this point in the history
  • Loading branch information
wolph committed Feb 8, 2023
1 parent ace90a5 commit 50ec301
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions python_utils/containers.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ class UniqueList(types.List[VT]):
def __init__(
self,
*args: VT,
on_duplicate: types.Literal['raise', 'ignore'] = 'ignore'
on_duplicate: types.Literal['raise', 'ignore'] = 'ignore',
):
self.on_duplicate = on_duplicate
self._set = set()
Expand Down Expand Up @@ -244,13 +244,11 @@ def __contains__(self, item):
return item in self._set

@types.overload
@abc.abstractmethod
def __setitem__(self, index: types.SupportsIndex, value: VT) -> None:
def __setitem__(self, indices: types.SupportsIndex, values: VT) -> None:
...

@types.overload
@abc.abstractmethod
def __setitem__(self, index: slice, value: types.Iterable[VT]) -> None:
def __setitem__(self, indices: slice, values: types.Iterable[VT]) -> None:
...

def __setitem__(self, indices, values) -> None:
Expand Down

0 comments on commit 50ec301

Please sign in to comment.