potiuk commented on code in PR #34278:
URL: https://github.com/apache/airflow/pull/34278#discussion_r1322901996
##########
airflow/example_dags/example_params_trigger_ui.py:
##########
@@ -89,13 +89,13 @@ def generate_french_greeting(name: str) -> str:
@task(task_id="print_greetings", trigger_rule=TriggerRule.ALL_DONE)
def print_greetings(greetings1, greetings2, greetings3) -> None:
- for g in greetings1 if greetings1 else []:
+ for g in greetings1 or []:
print(g)
- for g in greetings2 if greetings2 else []:
+ for g in greetings2 or []:
print(g)
- for g in greetings3 if greetings3 else []:
+ for g in greetings3 or []:
print(g)
- if not greetings1 and not greetings2 and not greetings3:
+ if not any((greetings1, greetings2, greetings3)):
Review Comment:
Agree with the second form
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]