Shlomit-B commented on issue #53971:
URL: https://github.com/apache/airflow/issues/53971#issuecomment-3172025020

   > [@Shlomit-B](https://github.com/Shlomit-B) Sure, lets talk about an 
implementation plan. What is your idea here?
   
   Based on your suggestion about the module-level variable, I thought an 
implementation could be a safe wrapper API that users apply as a decorator or 
context manager—decorators for function-based DAG factories and context 
managers for inline DAG creation or loops—to isolate errors during DAG 
creation. This wrapper would catch exceptions per DAG, safely register valid 
DAGs, and collect error information consistently.
   
   Internally, the wrapper would set the special module-level variable 
(__airflow_dag_parsing_errors) with collected errors, which Airflow would read 
during DAG parsing to report them in the UI.
   
   Let me know what you think.


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