josh-fell commented on issue #21669: URL: https://github.com/apache/airflow/issues/21669#issuecomment-1048160108
#19608 looks good for what it was designed to fix but I did find some other scenarios that the inference _does not_ handle properly. Mainly when the `@task` decorator is "called"/has an argument passed directly in the decorator (e.g. `@task(task_id="some_task") -> Dict: ...` or `@task(on_failure_callback=some_func) -> Dict: ...` ) the inference does not work. Although I have verified that this did not work in Airflow 2.2.3 but _does_ function properly on `main`. A workaround is to explicitly use `multiple_outputs=True` in any case. On the `main` branch, the inference was refactored and no longer uses the function signature with `inspect` but uses `typing_extensions` and seems to work much better. @jedcunningham This isn't a regression because the inference functionality doesn't work with directly passing args to the `@task` decorator currently. However, do you think logging an issue is warranted here for visibility? I think some unit tests should be added as well to handle this set of scenarios. WDYT? -- 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]
