Skip to content

[OSPRH-40683] Keep only valid metrics - #30

Merged
openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
lpiwowar:fix/update-metrics-endpoint-test
Nov 23, 2026
Merged

openshift-merge-bot[bot] merged 1 commit into
openstack-k8s-operators:mainfrom
lpiwowar:fix/update-metrics-endpoint-test

Conversation

@lpiwowar

@lpiwowar lpiwowar commented Nov 23, 2026 •

Copy link
Copy Markdown
Collaborator

The test asserted that /metrics exposes ls_started_in_degraded_mode, but it was removed in [1]. Since we are migrating to a newer version of lightspeed-stack that already contains [1], we have to remove it from the test (otherwise, it will fail).

[1] lightspeed-core/lightspeed-stack#3227


Failure encountered here while migrating to a new dev-latest image in openstack-k8s-operators/lightspeed-operator#163

The test asserted that /metrics exposes ls_started_in_degraded_mode,
but it was removed in [1]. Since we are migrating to a newer version
of lightspeed-stack that already contains [1], we have to remove it from
the test (otherwise, it will fail).

[1] lightspeed-core/lightspeed-stack#3227
@coderabbitai

coderabbitai Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Tests
    • Updated the metrics endpoint test expectations: the ls_started_in_degraded_mode gauge is no longer included in the expected metrics. This update changes test assertions only; no change to endpoint behavior is indicated. No other user-visible changes are noted.

The metrics endpoint integration test no longer includes the ls_started_in_degraded_mode gauge in its expected metrics list.

Changes: Metrics Endpoint Test

Layer / File(s) Summary
Update expected metrics
src/rhos_lightspeed_tests/tests/integration/test_metrics_endpoint.py
The test removes ls_started_in_degraded_mode from EXPECTED_METRICS.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Other

Suggested reviewers: jancervenka

Merge Risk: Minimal · up to 16bbe

This change drops a test expectation for a metric that the upstream project removed. It has no production impact, and the risk of merging is minimal.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title '[OSPRH-40683] Keep only valid metrics' is related to the change. The PR removes the test assertion for the removed ls_started_in_degraded_mode metric from the /metrics endpoint test, so the…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description states that the test asserted that /metrics exposes ls_started_in_degraded_mode, that the metric was removed upstream in lightspeed-stack PR #3227, and that the assertion must be remov…
Full details: Title check

Explanation

The title '[OSPRH-40683] Keep only valid metrics' is related to the change. The PR removes the test assertion for the removed ls_started_in_degraded_mode metric from the /metrics endpoint test, so the title describes the core change, though 'valid metrics' is somewhat broad and does not name the specific metric.

Full details: Description check

Explanation

The description states that the test asserted that /metrics exposes ls_started_in_degraded_mode, that the metric was removed upstream in lightspeed-stack PR #3227, and that the assertion must be removed so the test passes after migrating to a newer lightspeed-stack version. This matches the one-line removal in test_metrics_endpoint.py.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Central YAML (base), Organization UI (inherited)
  • Review profile: CHILL
  • Plan: Enterprise
  • Run ID: a83408b4-9c6e-4d95-ad31-91a7d27ce69c
Commits

Reviewing files that changed from the base of the PR and between 743c7b2 and 16bbef5.

Files selected for processing: 1

  • src/rhos_lightspeed_tests/tests/integration/test_metrics_endpoint.py
Files with no reviewable changes: 1

  • src/rhos_lightspeed_tests/tests/integration/test_metrics_endpoint.py

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 11 remain after this review.

@jancervenka jancervenka left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

thank you!:)

@openshift-ci

openshift-ci Bot commented Nov 23, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jancervenka, lpiwowar

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [jancervenka,lpiwowar]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot
openshift-merge-bot Bot merged commit 5e61424 into openstack-k8s-operators:main Nov 23, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants