XD-DENG commented on a change in pull request #4962: [AIRFLOW-3988] AIRFLOW-3988
URL: https://github.com/apache/airflow/pull/4962#discussion_r268398217
##########
File path: airflow/bin/cli.py
##########
@@ -2395,7 +2395,8 @@ def get_parser(cls, dag_parser=False):
subparsers.required = True
subparser_list = cls.dag_subparsers if dag_parser else
cls.subparsers_dict.keys()
- for sub in subparser_list:
+ sorted_subparser_list = sorted(subparser_list)
+ for sub in sorted_subparser_list:
Review comment:
Thanks @cchung100m , a nice change to me.
But not sure if we need an intermediate variable `sorted_subparser_list`
here. Can you consider directly changing `for sub in subparser_list:` into `for
sub in sorted(subparser_list):`? Personally I think it's good enough and a bit
more concise.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services