Skip to content

Commit 10f95ba

Browse files
committed
Fix documentation issues
1 parent 67734ee commit 10f95ba

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

pystreamapi/_streams/__base_stream.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,13 @@ def __drop_while(self, predicate: Callable[[Any], bool]):
121121

122122
def error_level(self, level: ErrorLevel, *exceptions)\
123123
-> Union["BaseStream[K]", NumericBaseStream]:
124+
"""
125+
Sets the error level of the stream. If an exception is raised during the execution of the
126+
stream, the error level determines what to do with the exception.
127+
:param level: Error level from ErrorLevel
128+
:param exceptions: Exceptions to ignore. If not provided, all exceptions will be ignored
129+
:return: The stream itself
130+
"""
124131
self._queue.append(Process(lambda: self._error_level(level, *exceptions)))
125132
return self
126133

pystreamapi/_streams/error/__error.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ def _error_level(self, level: ErrorLevel, *exceptions):
2929
Set the error level
3030
:param level: Error level from ErrorLevel
3131
:param exceptions: Exceptions to ignore. If not provided, all exceptions will be ignored
32-
:return: The stream itself
3332
"""
3433
self.__exceptions_to_ignore = exceptions or (Exception,)
3534
self.__error_level = level

0 commit comments

Comments
 (0)