o-nikolas commented on code in PR #77374:
URL: https://github.com/apache/airflow/pull/77374#discussion_r4644461538
##########
providers/cncf/kubernetes/docs/changelog.rst:
##########
@@ -27,6 +27,28 @@
Changelog
---------
+.. note::
+ The provider now accepts version 37 of the ``kubernetes`` client. That
version checks the
+ Kubernetes models that you create in your Dag files, for example in
``pod_override`` or in the
+ arguments of ``KubernetesPodOperator``:
+
+ * A field that holds text must get a string. Write
+ ``k8s.V1ResourceRequirements(limits={"cpu": "1"})``, not
``limits={"cpu": 1}``.
+ * You must give the fields by name. Write ``k8s.V1EnvVar(name="A",
value="b")``, not
+ ``k8s.V1EnvVar("A", "b")``.
+
+ Pod template files, job template files, ``pod_template_dict``, the
``affinity`` and
+ ``tolerations`` dictionaries, and the XCom sidecar resources of the
connection can keep numbers
+ in text fields. The provider changes those numbers
+ to strings, as version 36 of the client did. The opposite does not work
with version 37: a field
+ that holds a number or a boolean does not accept a string. Write
``runAsUser: 1000``, not
+ ``runAsUser: "1000"``, and ``hostNetwork: true``, not ``hostNetwork:
"true"``.
+
+ With version 37 of the client, the EKS executor of the Amazon provider
does not get a new token
+ after the cluster rejects the current one. The ``cncf.kubernetes`` extra
of the Amazon provider
+ keeps version 36 for that reason. If you install the client without that
extra and you use the
+ EKS executor, stay on version 36.
Review Comment:
Agreed, let's fix the EKS executor first, but @vincbeck do we have time to
do so before the current provider release? Should we hold these providers back
for a wave 2/RC2?
For context: On 37 the auth header is built in `param_serialize` before
`call_api`, so the 401 retry in `_EksApiClient` has to move up a layer to pick
up the new token. The retry (#76332) hasn't been released yet, so if the fix
lands before the next Amazon release, no released version has a retry that 37
breaks, and this PR can drop the Amazon extra pin and the EKS paragraph of this
note.
Dropping the pin also lets `uv.lock` move to 37, so CI would run the
provider against it. That will probably bring in the core failures Shahar
listed as well.
--
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]