Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
ebonnal committed Dec 25, 2023
1 parent 0868905 commit 9516e7b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
4 changes: 3 additions & 1 deletion streamable/_stream.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,9 @@ def filter(self, predicate: Callable[[T], bool]) -> "Stream[T]":
"""
return FilterStream(self, predicate)

def batch(self, size: int = 100, seconds: float = float("inf")) -> "Stream[List[T]]":
def batch(
self, size: int = 100, seconds: float = float("inf")
) -> "Stream[List[T]]":
"""
Batch elements of the Stream into lists of a specified size or within a specified time window.
Expand Down
4 changes: 3 additions & 1 deletion streamable/_visit/_explanation.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ def visit_do_stream(self, stream: _stream.DoStream) -> Any:

def visit_flatten_stream(self, stream: _stream.FlattenStream) -> Any:
name = "Flatten"
descr = f"using {stream.concurrency} thread{'s' if stream.concurrency > 1 else ''}"
descr = (
f"using {stream.concurrency} thread{'s' if stream.concurrency > 1 else ''}"
)
return self.visit_any_stream(stream, name, descr)

def visit_filter_stream(self, stream: _stream.FilterStream) -> Any:
Expand Down
4 changes: 3 additions & 1 deletion streamable/_visit/_iter.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ def visit_batch_stream(self, stream: _stream.BatchStream[U]) -> Iterator[T]:
)

def visit_slow_stream(self, stream: _stream.SlowStream[T]) -> Iterator[T]:
return _core.SlowingIteratorWrapper(stream.upstream._accept(self), stream.frequency)
return _core.SlowingIteratorWrapper(
stream.upstream._accept(self), stream.frequency
)

def visit_catch_stream(self, stream: _stream.CatchStream[T]) -> Iterator[T]:
if stream.when is not None:
Expand Down

0 comments on commit 9516e7b

Please sign in to comment.