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 2022/08/25 07:40:15 UTC

[GitHub] [airflow] uranusjr commented on a diff in pull request #25900: Add conf parameter to CLI for airflow dags test

uranusjr commented on code in PR #25900:
URL: https://github.com/apache/airflow/pull/25900#discussion_r954606621


##########
airflow/cli/commands/dag_command.py:
##########
@@ -451,13 +451,18 @@ def dag_list_dag_runs(args, dag=None, session=NEW_SESSION):
 @cli_utils.action_cli
 def dag_test(args, session=None):
     """Execute one single DagRun for a given DAG and execution date, using the DebugExecutor."""
+    run_conf = None
+    if args.conf:
+        run_conf = json.loads(args.conf)

Review Comment:
   We should add a try-catch here so invalid input doesn’t crash the command.



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