[bugfix] handle empty metric rows on the monitor detail page by P-Peaceful · Pull Request #4464 · apache/hertzbeat · GitHub
Skip to content

[bugfix] handle empty metric rows on the monitor detail page - #4464

Merged
zqr10159 merged 1 commit into
apache:1.9.1from
P-Peaceful:fix-issue-4460
Oct 20, 2026
Merged

zqr10159 merged 1 commit into
apache:1.9.1from
P-Peaceful:fix-issue-4460

Conversation

@P-Peaceful

Copy link
Copy Markdown
Contributor

What's changed?

Fixes #4460.

In HertzBeat 1.9.0, metrics that return zero rows can have a null valueRows field. The monitor detail page accesses valueRows.length when processing the response and rendering pagination, causing runtime errors that interrupt page rendering and affect navigation to historical charts.

Default null or undefined valueRows to an empty array so empty metrics can display the existing no-data state without disrupting the monitor detail page.

Screenshot

mark-shot-20261017-075732 mark-shot-20261017-075829

Checklist

  • I have read the Contributing Guide
  • I have written the necessary doc or comment.
  • I have added the necessary unit tests and all cases have passed.

Add or update API

  • I have added the necessary e2e tests and all cases have passed.

@zqr10159
zqr10159 merged commit 88f65fa into apache:1.9.1 Oct 20, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants