jedcunningham commented on code in PR #32061:
URL: https://github.com/apache/airflow/pull/32061#discussion_r1239080627


##########
airflow/models/baseoperator.py:
##########
@@ -1860,6 +1860,8 @@ def chain_linear(*elements: DependencyMixin | 
Sequence[DependencyMixin]):
 
     :param elements: a list of operators / lists of operators
     """
+    if len(elements) == 1:
+        raise ValueError("elements has length 1; did you forget to expand your 
list with `*`?")

Review Comment:
   "elements" feels a little weird to me here. Maybe something like:
   
   ```suggestion
           raise ValueError("Only 1 task or list of tasks passed; did you 
forget to expand your list with `*`?")
   ```
   
   Maybe save the "did you forget to expand" addition if the one thing we got 
is an iterable?



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