auyua9 opened a new pull request, #73161:
URL: https://github.com/apache/airflow/pull/73161
## Summary
`S3TablesCreateTableBucketOperator` documents `encryption_configuration` as
`(templated)` in its docstring, and `template_fields_renderers` already
declares a `json` renderer for it — but `template_fields` only listed
`table_bucket_name`.
Because the field was missing from `template_fields`, Airflow never rendered
it during task (re)parsing, so a templated SSE/KMS configuration such as
`encryption_configuration={"sseAlgorithm": "aws:kms", "kmsKeyArn": "{{
var.kms_arn }}"}` reached S3 as literal template text (or was pruned), and the
documented behavior did not hold.
This adds `encryption_configuration` to `template_fields` so the documented
templated value renders before `create_table_bucket`, and covers it with a
template-fields validation test that instantiates the operator with an
encryption configuration.
## Testing
- `uv run --with pytest python -m pytest
tests/unit/amazon/aws/operators/test_s3_tables.py` in `providers/amazon`: 28
passed, including the new
`test_template_fields_include_encryption_configuration`, which asserts the
field is in `template_fields` and passes `validate_template_fields` with a
rendered encryption configuration.
--
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]