Skip to content

airflow dags list-jobs missing state metavar and choices keyword arguments #31303

@jgarte

Description

@jgarte

What do you see as an issue?

The --state CLI flag on airflow dags list-jobs does not tell the user what arguments it can take.

ARG_STATE = Arg(("--state",), help="Only list the dag runs corresponding to the state")

It probably needs some keyword args similar to the following:

 metavar="(table, json, yaml, plain)",
 choices=("table", "json", "yaml", "plain"),

Solving the problem

The problem can be solved by adding those keyword arguments so that the user gets a suggestion for what state arguments can be passed in.

Anything else

Any suggestions on what can be a valid state would be much appreciated. Otherwise, I'll find some time to read through the code and/or docs and figure it out.

Are you willing to submit PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions