Ohashiro opened a new issue, #44613:
URL: https://github.com/apache/airflow/issues/44613

   ### Apache Airflow version
   
   Other Airflow 2 version (please specify below)
   
   ### If "Other Airflow 2 version" selected, which one?
   
   2.10.2
   
   ### What happened?
   
   We use the operator `PowerBIDatasetRefreshOperator` to refresh our PowerBI 
datasets. For one of the datasets, the refresh fails (and the refresh status 
received by the task is "Failed") but the task is marked as SUCCESS.
   
   <img width="998" alt="image" 
src="https://github.com/user-attachments/assets/888d3068-5ecd-433d-93ca-ecdb9b108b81";>
   
   
   ### What you think should happen instead?
   
   The Microsoft API documentation 
[here](https://learn.microsoft.com/en-us/rest/api/power-bi/datasets/get-refresh-history#refresh)
 lists the following status: Unknown, Completed, Failed, Disabled. I think that 
the task should fail if the refresh status is not "Completed".
   
   In the code 
[here](https://github.com/apache/airflow/blob/40821bfd5c54f3a39b3ff6e8352a4e3a20323e24/providers/src/airflow/providers/microsoft/azure/operators/powerbi.py#L129),
 the operator checks only if there is an error in the request to get the status.
   
   ### How to reproduce
   
   This bug appears when a Dataset can't be refreshed due to an error in the 
Dataset. Example: duplicate value in a column supposed to be "Unique"
   
   ### Operating System
   
   linux
   
   ### Versions of Apache Airflow Providers
   
   apache-airflow-providers-microsoft-azure==11.1.0
   
   ### Deployment
   
   Google Cloud Composer
   
   ### Deployment details
   
   _No response_
   
   ### Anything else?
   
   This bug occurs every time we run the operator.
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
   


-- 
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]

Reply via email to