Skip to content

Conversation

@dabla
Copy link
Contributor

@dabla dabla commented Jul 8, 2025

Allow MSGraphAsyncOperator and MSGraphSensor to always start from trigger instead of worker as this avoids unnecessary round trips to the scheduler.


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@dabla dabla marked this pull request as draft July 8, 2025 09:14
@dabla
Copy link
Contributor Author

dabla commented Jul 8, 2025

I think there is an issue with the defer_task method of TaskInstance, it should call render_template_fields first before calling the expand_start_trigger_args method. Otherwise non rendered fields would be passed to the triggerer to instantiate, which is a not the same behaviour as with regular operators defering afterwards.

@dabla
Copy link
Contributor Author

dabla commented Jul 8, 2025

Ok overriding the expand_start_trigger_args doesn't help because the scheduler has a serialized version of the task (e.g. operator), so it won't take into account that overriden method. So now remains the question, how do we fix this issue. This is clearly a situation which hasn't been thought about.

@dabla
Copy link
Contributor Author

dabla commented Jul 9, 2025

This PR must be merged before this one can.

@dabla
Copy link
Contributor Author

dabla commented Sep 2, 2025

Created new PR which attempts to fix template rendering with start from trigger, as long as template rendering in triggerer isn't fixed, this PR can't be merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants