pyspark.sql.streaming.StreamingQuery.exception

StreamingQuery.exception() → Optional[pyspark.sql.utils.StreamingQueryException]
Returns
StreamingQueryException

the StreamingQueryException if the query was terminated by an exception, or None.