Shnekit opened a new pull request, #62962: URL: https://github.com/apache/airflow/pull/62962
## Summary This PR fixes two issues with the `SageMakerNotebookOperator` and its underlying hook when `domain_id`, `project_id`, and `domain_region` are passed as parameters. ### Fixes **1. Duplicate `_get_sagemaker_studio_config` in hook** The hook had a duplicate method — the first (incomplete) version only set `local`, missing `domain_identifier`, `project_identifier`, and `datazone_domain_region`. The duplicate has been removed, leaving only the correct implementation. **2. Add `template_fields` to `SageMakerNotebookOperator`** Without `template_fields`, passing XCom references (e.g. `task_instance.xcom_pull(...)`) for `domain_id`, `project_id`, or `domain_region` caused a `ParamValidationError` because the hook was instantiated before Airflow resolved the XCom values to actual strings. Adding these to `template_fields` ensures they are rendered before `execute()` is called. ### System Tests - Updated `example_sagemaker_unified_studio` to remove deprecated env vars (`ENVIRONMENT_ID`, `SCOPE_NAME`, `STAGE`, `ENDPOINT`) - Added `example_sagemaker_unified_studio_explicit_params` — identical flow but passes `domain_id`, `project_id`, `domain_region` directly as operator parameters instead of environment variables -- 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]
