yunusakca opened a new pull request, #71201: URL: https://github.com/apache/airflow/pull/71201
Moves `CloudBatchSubmitJobOperator`'s `Job` protobuf → dict normalization out of `__init__`, as part of the exemption-list burn-down tracked in #70296. Template fields are rendered after the constructor runs, so reading a template field's value inside `__init__` operates on the un-rendered Jinja expression rather than the real value. The `job` protobuf-to-dict conversion — added for #37217 so the renderer can descend into nested fields such as a runnable's container commands — is exactly that pattern. The conversion has to run *before* Jinja rendering, not after: moving it to `execute()` would silently stop nested Jinja expressions inside a `Job` protobuf from ever being rendered. It now lives in `prepare_template()`, the hook Airflow runs after construction but before rendering, matching the pattern `CloudBuildCreateBuildOperator` already uses in this provider. `CloudBatchSubmitJobOperator`'s entry is removed from `validate_operators_init_exemptions.txt`. The existing rendering test already covers both a `dict` and a protobuf `Job` input; a new test asserts the normalization happens in `prepare_template()` rather than the constructor. related: #70296 --- ##### Was generative AI tooling used to co-author this PR? - [X] Yes — Claude Code (Sonnet 5 and Opus 5) Generated-by: Claude Code (Sonnet 5 and Opus 5) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions) -- 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]
