Skip to content

fix: ci issue - #4357

Merged
Hardikl merged 1 commit into
mainfrom
rg2-fix-ci-1
Jul 22, 2026
Merged

fix: ci issue#4357
Hardikl merged 1 commit into
mainfrom
rg2-fix-ci-1

Conversation

@rahulguptajss

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings July 22, 2026 10:23
@cla-bot cla-bot Bot added the cla-signed label Jul 22, 2026

Copilot AI 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.

Pull request overview

This PR adjusts the MetricAgent compute-metric behavior to avoid dropping derived metrics in single-matrix mode when a non-primary operand metric exists but has no value for a given instance (treating that missing operand as 0 instead of skipping the derived metric), and adds a regression test for the scenario.

Changes:

  • Update computeMetrics to only skip derived metric computation on missing operand values in the multi-matrix case.
  • Add a unit test covering single-matrix computation when optional operands are missing for an instance.
  • Minor import ordering cleanup in the test file.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
cmd/poller/plugin/metricagent/metric_agent.go Changes missing-operand handling so single-matrix rules don’t skip derived metrics when an operand value is absent.
cmd/poller/plugin/metricagent/metric_agent_test.go Adds a regression test ensuring missing optional operands are treated as 0 (and fixes import order).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread cmd/poller/plugin/metricagent/metric_agent.go
@Hardikl
Hardikl merged commit 8757c90 into main Jul 22, 2026
14 checks passed
@Hardikl
Hardikl deleted the rg2-fix-ci-1 branch July 22, 2026 11:56
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.

4 participants