dchvn commented on a change in pull request #34414:
URL: https://github.com/apache/spark/pull/34414#discussion_r738065166
##########
File path: python/pyspark/sql/streaming.py
##########
@@ -1185,7 +1185,8 @@ def doesMethodExist(method_name: str) -> bool:
close_exists = doesMethodExist('close')
def func_with_open_process_close(partition_id: Any, iterator:
Iterator) -> Iterator:
- epoch_id =
TaskContext.get().getLocalProperty('streaming.sql.batchId')
+ epoch_id = TaskContext.get().getLocalProperty( # type:
ignore[union-attr]
Review comment:
Because ```TaskContext.get()``` return an ```Optional["TaskContext"]```.
Should i use ```cast```? @HyukjinKwon
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]