Repository navigation
fix(monitoring): exclude caller labels at the gateway source - #6459
Conversation
Fail-to-Pass Check: expected redThis change deletes the gate check Exit status 1. Live check after the merge and the Argo CD sync of Application
|
A fix that removes a manifest rule also deletes the gate check of the rule. `devops ci fail-to-pass` then replayed the gate row of that module. The base run uses the tests of the head, so the deleted check ran on neither tree, and no case could prove the fix (see #6459). A changed gate check module now only loses checks when its head keeps the top-level statements of its base in the same order, by syntax tree, and leaves out at least one `def check_*` and only names that the head does not use and that run no code at import. A fix that changes no source code, and whose gate check modules only lose checks or are deleted, passes with no replay. The report names each deleted check as `<module>.<check>`. A fix that adds or changes a gate case still needs a case that fails on its base. On the branch of #6439, the command now exits 0 and names the deleted check. Closes #6456 Change: `openspec/changes/archive/2026-11-19-6456-deleted-gate-check-needs-no-proof/`
920cbe8 to
369d165
Compare
Check resultsHead commit:
Fail-to-pass run: https://github.com/dan-petty/devops-cli/actions/runs/44628265777/job/135927758675 Skipped check: Plan Check |
Plan #6439 as an OpenSpec change. LiteLLM v1.103.11 reads litellm_settings.prometheus_exclude_labels (litellm/__init__.py:477-478, litellm/integrations/prometheus.py:275, :897-919, :1158-1178), so the gateway excludes client_ip and user_agent before exposition. The two labeldrop rules of the ServiceMonitor and the value check of the k8s row go. The spec delta removes the labeldrop requirements and adds the source-exclusion requirement with a validator command and live checks.
Set litellm_settings.prometheus_exclude_labels to client_ip and user_agent, before callbacks. LiteLLM v1.103.11 removes the two labels before exposition and adds the callers into one series (litellm/integrations/prometheus.py:897-919, :1158-1178), so no two series collide in Prometheus. The comment says why the key comes first.
The gateway now excludes client_ip and user_agent at the source, so the ServiceMonitor keeps no metricRelabelings. The labeldrop rules dropped the labels after LiteLLM had split the counts, so series with the same labels and different values collided in Prometheus (#6439). Delete the gate check that asserted the labeldrop list, the port, the path and the interval of the ServiceMonitor. docs/TESTING.md forbids a check of a manifest value, so no check of the new key replaces it. The two checks that no dashboard query and no alert expression reads the labels stay.
369d165 to
0968753
Compare
🤖 I have created a release *beep* *boop* --- ## [0.182.0](v0.181.1...v0.182.0) (2026-11-19) ### Features * **roadmap:** Post delivery PR evidence before ready ([#6426](#6426)) ([a3891c0](a3891c0)) ### Bug Fixes * **ci:** fail-to-pass needs no proof for a deleted gate check ([#6465](#6465)) ([52e50f7](52e50f7)) * **deps:** ignore GHSA-qx49-fqc8-xw99 of mcp 1.29.0 until 2026-11-22 ([#6482](#6482)) ([99434a9](99434a9)), closes [#6481](#6481) * **monitoring:** exclude caller labels at the gateway source ([#6459](#6459)) ([bc57c1e](bc57c1e)) * **security:** Keep host-only SSH keys off GitHub ([#6473](#6473)) ([65771a4](65771a4)) --- 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>
The gateway now excludes
client_ipanduser_agentat the source with LiteLLM's ownlitellm_settings.prometheus_exclude_labels, set beforecallbacks. LiteLLM v1.103.11 reads the key (litellm/integrations/prometheus.py:275,:1188-1204) and adds the counts of all callers into one series before exposition. The twolabeldroprules leave the gateway ServiceMonitor, and the gate check that asserted them leaves the k8s row.The
labeldroprules of #5896 made two series that differ only in these labels identical. Prometheus refused the remote write of Alloy with "duplicate sample for timestamp", and Alloy dropped full batches: 8.1 % of all samples on 2026-11-19, with gaps in targets that have no fault. Exclusion at the source stops the collisions and keeps the bound on the series count of #4545.Closes #6439
Change:
openspec/changes/archive/2026-11-19-6439-exclude-gateway-caller-labels/