You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "HyukjinKwon (via GitHub)" <gi...@apache.org> on 2023/08/28 00:59:48 UTC
[GitHub] [spark] HyukjinKwon commented on a diff in pull request #42686: [SPARK-44971][PYTHON] StreamingQueryProgress event fromJson bug fix
HyukjinKwon commented on code in PR #42686:
URL: https://github.com/apache/spark/pull/42686#discussion_r1306790110
##########
python/pyspark/sql/streaming/listener.py:
##########
@@ -477,7 +477,7 @@ def fromJson(cls, j: Dict[str, Any]) -> "StreamingQueryProgress":
name=j["name"],
timestamp=j["timestamp"],
batchId=j["batchId"],
- batchDuration=j["batchDuration"],
+ batchDuration=j["batchDuration"] if "batchDuration" in j else None,
Review Comment:
```suggestion
batchDuration=j.get("batchDuration", None),
```
--
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: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org