This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new a61cb1b949b Fix Celery Executor on Airflow 2.x again. (#48806)
a61cb1b949b is described below
commit a61cb1b949b20c4660e2ba9d92f85791f61e632b
Author: Ash Berlin-Taylor <[email protected]>
AuthorDate: Fri Apr 4 19:49:52 2025 +0100
Fix Celery Executor on Airflow 2.x again. (#48806)
Prior to 984c61d28 this code looked like:
```python
result = task_to_run.apply_async(args=[command], queue=queue)
```
Closes #47781
---
.../src/airflow/providers/celery/executors/celery_executor_utils.py | 2 ++
1 file changed, 2 insertions(+)
diff --git
a/providers/celery/src/airflow/providers/celery/executors/celery_executor_utils.py
b/providers/celery/src/airflow/providers/celery/executors/celery_executor_utils.py
index cbe3eec2309..555c4147dd0 100644
---
a/providers/celery/src/airflow/providers/celery/executors/celery_executor_utils.py
+++
b/providers/celery/src/airflow/providers/celery/executors/celery_executor_utils.py
@@ -265,6 +265,8 @@ def send_task_to_executor(
if TYPE_CHECKING:
assert isinstance(args, workloads.BaseWorkload)
args = (args.model_dump_json(),)
+ else:
+ args = [args] # type: ignore[list-item]
try:
with timeout(seconds=OPERATION_TIMEOUT):
result = task_to_run.apply_async(args=args, queue=queue)