Repository navigation
fix(ingestion): cap kubernetes client below 36.0.0 - #28331
Merged
Merged
Conversation
kubernetes==36.0.0 regressed in-cluster authentication, breaking the KubernetesSecretsManager in the hybrid runner. Mechanism: - Configuration.auth_settings() in v36 looks up the bearer token under api_key['BearerToken'], but load_incluster_config() / load_kube_config() still write it to api_key['authorization']. The mismatch means no Authorization header is sent — the API treats the request as system:anonymous and returns 403 Forbidden when reading the secret. The caller surfaces this as "password authentication failed." Proof it's the client, not env/RBAC: - curl with the same mounted SA token returns 200. - kubernetes 35.0.0 works; 36.0.0 doesn't. Upstream is open and unfixed: - kubernetes-client/python#2582 - kubernetes-client/python#2584 The previous unbounded `>=21.0.0` pin caused the post-2026-05-19 image build to pull 36.0.0. Capping to <36 keeps us on the working 35.x line and guards against further 36.x regressions until upstream ships a patch — at which point this becomes `!=36.0.0` or a fixed `>=36.x`.
Code Review ✅ ApprovedCaps the kubernetes client dependency below 36.0.0 to prevent a regression in in-cluster authentication. No issues found. OptionsDisplay: compact → Showing less information. Comment with these commands to change:
Was this helpful? React with 👍 / 👎 | Gitar |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR caps the Python kubernetes client dependency for the ingestion package to avoid pulling kubernetes==36.x, which (per the linked upstream issues) regresses in-cluster authentication and breaks KubernetesSecretsManager usage in certain environments (e.g., hybrid runner).
Changes:
- Update ingestion base dependency spec from
kubernetes>=21.0.0tokubernetes>=21.0.0,<36to prevent installing the regressing 36.x line.
pmbrull
approved these changes
May 21, 2026
|
Contributor
🟡 Playwright Results — all passed (9 flaky)✅ 4150 passed · ❌ 0 failed · 🟡 9 flaky · ⏭️ 90 skipped
🟡 9 flaky test(s) (passed on retry)
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
IceS2
added a commit
that referenced
this pull request
May 21, 2026
kubernetes==36.0.0 regressed in-cluster authentication, breaking the KubernetesSecretsManager in the hybrid runner. Mechanism: - Configuration.auth_settings() in v36 looks up the bearer token under api_key['BearerToken'], but load_incluster_config() / load_kube_config() still write it to api_key['authorization']. The mismatch means no Authorization header is sent — the API treats the request as system:anonymous and returns 403 Forbidden when reading the secret. The caller surfaces this as "password authentication failed." Proof it's the client, not env/RBAC: - curl with the same mounted SA token returns 200. - kubernetes 35.0.0 works; 36.0.0 doesn't. Upstream is open and unfixed: - kubernetes-client/python#2582 - kubernetes-client/python#2584 The previous unbounded `>=21.0.0` pin caused the post-2026-05-19 image build to pull 36.0.0. Capping to <36 keeps us on the working 35.x line and guards against further 36.x regressions until upstream ships a patch — at which point this becomes `!=36.0.0` or a fixed `>=36.x`.
IceS2
added a commit
that referenced
this pull request
May 21, 2026
kubernetes==36.0.0 regressed in-cluster authentication, breaking the KubernetesSecretsManager in the hybrid runner. Mechanism: - Configuration.auth_settings() in v36 looks up the bearer token under api_key['BearerToken'], but load_incluster_config() / load_kube_config() still write it to api_key['authorization']. The mismatch means no Authorization header is sent — the API treats the request as system:anonymous and returns 403 Forbidden when reading the secret. The caller surfaces this as "password authentication failed." Proof it's the client, not env/RBAC: - curl with the same mounted SA token returns 200. - kubernetes 35.0.0 works; 36.0.0 doesn't. Upstream is open and unfixed: - kubernetes-client/python#2582 - kubernetes-client/python#2584 The previous unbounded `>=21.0.0` pin caused the post-2026-05-19 image build to pull 36.0.0. Capping to <36 keeps us on the working 35.x line and guards against further 36.x regressions until upstream ships a patch — at which point this becomes `!=36.0.0` or a fixed `>=36.x`.
Merged
9 of 11 tasks
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Summary
One-line dependency cap to recover the KubernetesSecretsManager in the hybrid runner. The unbounded
>=21.0.0pin let the post-2026-05-19 image build pullkubernetes==36.0.0, which regressed in-cluster auth.Why
kubernetes==36.0.0broke the KubernetesSecretsManager:Configuration.auth_settings()(v36) looks up the bearer token underapi_key['BearerToken'], butload_incluster_config()/load_kube_config()still write it toapi_key['authorization'].Authorizationheader is sent. The API treats the request assystem:anonymous→ 403 Forbidden when reading the secret, which surfaces to the caller aspassword authentication failed.Proof it's the client, not env / RBAC
curlwith the same mounted SA token returns 200.kubernetes==35.0.0works.kubernetes==36.0.0doesn't.Upstream tracking (open, unfixed)
Configuration.auth_settings()returns empty dict in v36.0.0 - all BearerToken-authed requests go anonymous kubernetes-client/python#2582 — load_incluster_config sets api_key['authorization'] but auth_settings expects api_key['BearerToken'] in v36Why
<36and not!=36.0.0<36keeps the resolver on the known-good 35.x line and protects against any other 36.x regression discovered before upstream fixes 2582. Once upstream ships a fix, this becomes!=36.0.0or a fixed>=36.x.Test plan