mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-10 08:28:25 +00:00
fix(proxy): type the equality operand in the stream buffer
list(other) on an isinstance-narrowed Sequence[Unknown] added one reportUnknownArgumentType, which tripped the basedpyright delta gate. Bind it to Sequence[object] first; behaviour is unchanged.
This commit is contained in:
parent
2350324fd6
commit
ed916038be
1 changed files with 4 additions and 1 deletions
|
|
@ -108,7 +108,10 @@ class BoundedChunkBuffer(Sequence[bytes]):
|
|||
return len(self._frames())
|
||||
|
||||
def __eq__(self, other: object) -> bool:
|
||||
return isinstance(other, Sequence) and list(self) == list(other)
|
||||
if not isinstance(other, Sequence):
|
||||
return False
|
||||
other_items: Final[Sequence[object]] = other
|
||||
return list(self) == list(other_items)
|
||||
|
||||
def __bool__(self) -> bool:
|
||||
return self.total_bytes > 0
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue