ashb commented on a change in pull request #19965:
URL: https://github.com/apache/airflow/pull/19965#discussion_r778123479



##########
File path: airflow/decorators/base.py
##########
@@ -275,10 +275,10 @@ def map(
     def partial(
         self, *, dag: Optional["DAG"] = None, task_group: 
Optional["TaskGroup"] = None, **kwargs
     ) -> "_TaskDecorator[T, OperatorSubclass]":
+        if self.kwargs:
+            raise RuntimeError("Already a partial task")

Review comment:
       Hmmm, this one doesn't behave correctly right now, as:
   
   ```
   @taks(task_id='x')
   def y():
       ...
   ```
   
   This currently stores `task_id` in the `self.kwargs`




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