You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/10/19 15:48:45 UTC

[GitHub] [airflow] mik-laj opened a new issue #19080: Display DAGs dependencies in CLI

mik-laj opened a new issue #19080:
URL: https://github.com/apache/airflow/issues/19080


   ### Description
   
   Recently, we added [a new DAG dependencies view](https://github.com/apache/airflow/pull/13199) to the webserver. It would be helpful if a similar diagram could also be displayed/generated using the CLI. For now, only [one DAG can be displayed](http://airflow.apache.org/docs/apache-airflow/stable/usage-cli.html#exporting-dag-structure-as-an-image) using CLI.
   ![image](https://user-images.githubusercontent.com/12058428/137945580-6a33f919-2648-4980-bd2c-b40cfcacc9fe.png)
   
   If anyone is interested, I will be happy to help with the review.
   
   ### Use case/motivation
   
   * Keep parity between CLI and web serwer.
   * Enable the writing of scripts that use these diagrams, e.g. for attaching in the documentation.
   
   ### Related issues
   
   https://github.com/apache/airflow/pull/13199/files
   
   ### Are you willing to submit a PR?
   
   - [ ] 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: commits-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] mik-laj commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
mik-laj commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957172087


   @subkanthi  Assgined.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] tanvimoharir commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
tanvimoharir commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-947715091


   Hi, 
   I would like to contribute. However I'm new to this and would need some direction.
   Thanks


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] subkanthi commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
subkanthi commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-962655257


   Observation: the UI retrieves the dag dependencies of all the DAG's
   `SELECT serialized_dag.dag_id AS serialized_dag_dag_id, json_extract(serialized_dag.data, %s) AS json_extract_1 
   FROM serialized_dag`
   
   But for the CLI, dag dependencies need to be filtered for the specific DAG passed by the user.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] mik-laj commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
mik-laj commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957172087


   @subkanthi  Assgined.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] mik-laj commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
mik-laj commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-949056412


   Here is code that display DAG:
   https://github.com/apache/airflow/blob/9ad8d2e49fc3394f58c6b92e40e9d84ce37fb9e1/airflow/cli/commands/dag_command.py#L187-L228
   Here is PR that add DAG dependencies view to UI:
   https://github.com/apache/airflow/pull/13199
   You have to modify this code so that it displays DAG dependencies, not tasks dependencies.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] subkanthi commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
subkanthi commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957013159


   can I take this on please.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] mik-laj commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
mik-laj commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957172087


   @subkanthi  Assgined.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] potiuk closed issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
potiuk closed issue #19080:
URL: https://github.com/apache/airflow/issues/19080


   


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] mik-laj commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
mik-laj commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-962754920


   @subkanthi  Why do you want to filter dependencies based on DAG ID? I think it makes sense to see all the dependencies in one diagram.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] tanvimoharir commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
tanvimoharir commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-949563625


   > Here is code that display DAG:
   > 
   > https://github.com/apache/airflow/blob/9ad8d2e49fc3394f58c6b92e40e9d84ce37fb9e1/airflow/cli/commands/dag_command.py#L187-L228
   > 
   > 
   > Here is PR that add DAG dependencies view to UI:
   > #13199
   > You have to modify this code so that it displays DAG dependencies, not tasks dependencies.
   
   Thanks! I will look into this.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] subkanthi commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
subkanthi commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957013159


   can I take this on please.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] subkanthi commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
subkanthi commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-957013159


   can I take this on please.


-- 
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-unsubscribe@airflow.apache.org

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



[GitHub] [airflow] subkanthi commented on issue #19080: Display DAGs dependencies in CLI

Posted by GitBox <gi...@apache.org>.
subkanthi commented on issue #19080:
URL: https://github.com/apache/airflow/issues/19080#issuecomment-963296347


   > @subkanthi Why do you want to filter dependencies based on DAG ID? I think it makes sense to see all the dependencies in one diagram.
   
   Hi @mik-laj , its good you actually looked at this comment, the current dag show takes the DAG id, so I assumed for the dag dependencies we need to show that specific DAG. Maybe its nice to have one for specific DAG id , and it no arguments are passed, show the dag dependencies for all DAGs.
   
   `airflow dags show example_external_task_marker_parent --save output.jpg`


-- 
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-unsubscribe@airflow.apache.org

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