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


##########
dev/breeze/src/airflow_breeze/utils/coertions.py:
##########
@@ -30,4 +30,4 @@ def coerce_bool_value(value: str | bool) -> bool:
 
 
 def one_or_none_set(iterable: Iterable[bool]) -> bool:
-    return len([i for i in iterable if i]) in (0, 1)
+    return sum(1 for i in iterable if i) in (0, 1)

Review Comment:
   ```suggestion
       return 0 <= sum(1 for i in iterable if i) <= 1
   ```



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

Reply via email to