Aaryan123456679 opened a new pull request, #70234:
URL: https://github.com/apache/airflow/pull/70234

   `airflow dags test` (and calling `KubernetesPodOperator.dry_run()` directly) 
failed outside a real cluster because `build_pod_request_obj()` unconditionally 
read `hook.is_in_cluster` to set the `airflow_kpo_in_cluster` label. That 
property instantiates a Kubernetes API client, which requires kube 
credentials/config to be available — something a dry run must not need.
   
   This adds a keyword-only `dry_run` parameter to `build_pod_request_obj()` 
(default `False`, so existing callers are unaffected) and has `dry_run()` skip 
the `is_in_cluster` lookup when set.
   
   closes: #45812


-- 
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]

Reply via email to