vandonr-amz commented on code in PR #30466:
URL: https://github.com/apache/airflow/pull/30466#discussion_r1157695648


##########
airflow/providers/amazon/aws/hooks/quicksight.py:
##########
@@ -141,12 +148,14 @@ def wait_for_state(
         status = self.get_status(aws_account_id, data_set_id, ingestion_id)
         while status in self.NON_TERMINAL_STATES and status != target_state:
             self.log.info("Current status is %s", status)
-            time.sleep(check_interval)
-            sec += check_interval
             if status in self.FAILED_STATES:
-                raise AirflowException("The Amazon QuickSight Ingestion 
failed!")
+                info = self.get_error_info(aws_account_id, data_set_id, 
ingestion_id)
+                raise AirflowException(f"The Amazon QuickSight Ingestion 
failed. Error info: {info}")
             if status == "CANCELLED":
                 raise AirflowException("The Amazon QuickSight SPICE ingestion 
cancelled!")
+            # wait and try again
+            time.sleep(check_interval)
+            sec += check_interval

Review Comment:
   ah yes I forgot to mention that in the description, I'll edit it !



-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to