You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/10/22 18:39:29 UTC

[GitHub] [airflow] dstandish commented on a diff in pull request #27197: Drop support for providing ``resource`` as dict in ``KubernetesPodOperator``

dstandish commented on code in PR #27197:
URL: https://github.com/apache/airflow/pull/27197#discussion_r1002554818


##########
airflow/providers/cncf/kubernetes/operators/kubernetes_pod.py:
##########
@@ -213,21 +212,10 @@ def __init__(
         pod_runtime_info_envs: list[k8s.V1EnvVar] | None = None,
         termination_grace_period: int | None = None,
         configmaps: list[str] | None = None,
-        resources: dict[str, Any] | None = None,
         **kwargs,
     ) -> None:
 
-        if isinstance(resources, k8s.V1ResourceRequirements):
-            warnings.warn(
-                "Specifying resources for the launched pod with 'resources' is deprecated. "
-                "Use 'container_resources' instead.",
-                category=DeprecationWarning,
-                stacklevel=2,
-            )
-            container_resources = resources
-            resources = None
-
-        super().__init__(resources=resources, **kwargs)
+        super().__init__(**kwargs)

Review Comment:
   i suppose we could keep the check, but make it raise an error now? 



-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org