[ 
https://issues.apache.org/jira/browse/AIRFLOW-4873?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16924469#comment-16924469
 ] 

Ash Berlin-Taylor commented on AIRFLOW-4873:
--------------------------------------------

To be able to get a dag_id, airflow needs to parse and execute the file. But if 
there is a syntax error in the file the parsing failed, so airflow can't tell 
what dag IDs (remember, can be more than one!) are in that file since the 
parsing failed!

I'm going to close this issue as I don't think what you are asking for is 
possible - if you attempt a PR then please reopen this issue.

> Improve BROKEN DAG error message by specifying dag_id 
> ------------------------------------------------------
>
>                 Key: AIRFLOW-4873
>                 URL: https://issues.apache.org/jira/browse/AIRFLOW-4873
>             Project: Apache Airflow
>          Issue Type: Improvement
>          Components: ui
>    Affects Versions: 1.10.3
>            Reporter: jack
>            Assignee: Omkar
>            Priority: Major
>              Labels: easy-fix
>
> In some cases there is a broken DAG message appear in the UI:
>  
> {code:java}
> Broken DAG: [/home/airflow/dags/my_dag.py] No module named 'HelperClass'  
> {code}
>  
> The problem here is that the error indicates only the file name but it 
> doesn't specify the dag_id.
> The error could be improved to (or similar):
>  
> {code:java}
> Broken DAG: DAG_ID : [/home/airflow/dags/my_dag.py] No module named 
> 'HelperClass' {code}
>  



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Reply via email to