@@ -60,7 +60,7 @@ def has_results_or_errors(self) -> Event:
6060 **INTERNAL**
6161 """
6262 return self ._has_results_or_errors_evt
63-
63+
6464 @property
6565 def results_or_errors_type (self ) -> ParsedResultType :
6666 """
@@ -74,7 +74,7 @@ def token_stream_exhausted(self) -> bool:
7474 **INTERNAL**
7575 """
7676 return self ._token_stream_exhausted
77-
77+
7878 def _continue_processing (self ) -> bool :
7979 """
8080 **INTERNAL**
@@ -108,7 +108,7 @@ async def _handle_json_result(self, row: bytes) -> None:
108108 def _handle_notification (self , result_type : Optional [ParsedResultType ]= None ) -> None :
109109 if self ._has_results_or_errors_evt .is_set ():
110110 return
111-
111+
112112 if result_type is None :
113113 self ._results_or_errors_type = ParsedResultType .END
114114 self ._has_results_or_errors_evt .set ()
@@ -140,14 +140,14 @@ async def _process_token_stream(self) -> None:
140140 result_type = ParsedResultType .ERROR if self ._json_token_parser .has_errors else ParsedResultType .END
141141 await self ._send_to_stream (ParsedResult (self ._json_token_parser .get_result (), result_type ), close = True )
142142 self ._handle_notification (result_type )
143-
143+
144144 async def read (self , size : Optional [int ]= - 1 ) -> bytes :
145145 """
146146 **INTERNAL**
147147 """
148148 if size is None or size == 0 or self ._http_stream_exhausted :
149149 return b''
150-
150+
151151 while not self ._http_stream_exhausted :
152152 if size >= 0 and len (self ._http_response_buffer ) > size :
153153 break
@@ -181,4 +181,4 @@ async def start_parsing(self) -> None:
181181
182182 async def continue_parsing (self ) -> None :
183183 # TODO: error is _json_stream_parser is None?
184- await self ._process_token_stream ()
184+ await self ._process_token_stream ()
0 commit comments