Skip to content

fix(k8s): key claim table by chart version - #3812

Merged
dan-petty merged 2 commits into
mainfrom
fix/2519-claim-table-chart-version
Nov 6, 2026
Merged

dan-petty merged 2 commits into
mainfrom
fix/2519-claim-table-chart-version

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

Issue #2519: CHART_CLAIMS in tests/core/test_k8s_local_path_placement.py has the chart name as its key. No check ties an entry to the chart version that an Argo CD Application pins. A chart release can move the claim switch or the affinity path of a pod. The test then reads a value that the chart no longer uses, and it passes. The pod can bind its volume on the control-plane node. The token test of #1652 solved this with a key of chart and version, and a check that the key set equals pinned_charts(). This change gives CHART_CLAIMS the same key and the same check.

Closes #2519

Change: openspec/changes/archive/2026-11-06-2519-the-claim-table-of-the-local/

The claim table CHART_CLAIMS had the chart name as its key. A chart release
can move the value that sets a claim or an affinity, and the test then passed
on a stale path. The key is now the chart and the version that the entry was
read from, as in the token test of #1652. A new test asserts that the keys
equal the pinned charts, so a chart bump fails until a person reads the claim
values of the new version again.

Closes #2519
@dan-petty dan-petty added type/bug Type bug: the code does not do what it must scope/k8s Kubernetes commands, Helm charts, pods, services, and policies labels Nov 6, 2026
@dan-petty

Copy link
Copy Markdown
Owner Author

Test evidence for #2519.

  • Branch is on the tip of origin/main (c714551). No rebase and no conflict.
  • uv run pytest tests/core/test_k8s_local_path_placement.py: 11 passed.
  • The pre-push fast static checks passed.
  • uv run devops ci fail-to-pass --base origin/main reports "0 failed on base". The reason: the table CHART_CLAIMS is in the test file. The command overlays the test tree of this branch on the base tree, so the new table and the new test both come from this branch, and the test passes. The command cannot show a fail for a change that is itself a test file.
  • Manual fail-to-pass run: I put the new test body (sorted(pinned_charts() ^ CHART_CLAIMS.keys(), key=str) == []) in the base test file, with the base name-keyed table. It fails: Left contains 36 more items, first extra item: ('argo-cd', '10.9.6'). With the table of this branch it passes.

@dan-petty
dan-petty marked this pull request as ready for review November 6, 2026 17:35
@dan-petty
dan-petty merged commit 555280f into main Nov 6, 2026
23 checks passed
@dan-petty
dan-petty deleted the fix/2519-claim-table-chart-version branch November 6, 2026 17:38
dan-petty pushed a commit that referenced this pull request Nov 6, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.70.1](v0.70.0...v0.70.1)
(2026-11-06)


### Bug Fixes

* **k8s:** key claim table by chart version
([#3812](#3812))
([555280f](555280f))
* **openspec:** accept every Verification line of an active plan
([#3809](#3809))
([e999bfe](e999bfe))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/k8s Kubernetes commands, Helm charts, pods, services, and policies type/bug Type bug: the code does not do what it must

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(k8s): key claim table by chart version

1 participant