Skip to content

test: allow zero min in eventloopdelay histogram#63387

Closed
trivikr wants to merge 1 commit into
nodejs:mainfrom
trivikr:flaky-test-performance-eventloopdelay
Closed

test: allow zero min in eventloopdelay histogram#63387
trivikr wants to merge 1 commit into
nodejs:mainfrom
trivikr:flaky-test-performance-eventloopdelay

Conversation

@trivikr
Copy link
Copy Markdown
Member

@trivikr trivikr commented May 17, 2026

The test-performance-eventloopdelay test can fail intermittently after
recording samples if one event loop delay sample is 0.

HDR histograms allow 0 values, and hdr_min() returns 0 when bucket 0 has
a count. This can happen when two successive uv_hrtime() reads observe the
same effective clock value.

This updates the test to keep requiring recorded samples while allowing
histogram.min to be 0.

Refs: https://github.com/nodejs/reliability/blob/main/reports/2026-05-17.md#jstest-failure


Assisted-by: openai:gpt-5.5

The event loop delay histogram can record a zero-valued sample when
two successive clock reads observe the same effective time. Keep
checking that samples were recorded, but do not require the minimum
sample to be positive.

Signed-off-by: Kamat, Trivikram <16024985+trivikr@users.noreply.github.com>
Assisted-by: openai:gpt-5.5
@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. test Issues and PRs related to the tests. labels May 17, 2026
@lpinca
Copy link
Copy Markdown
Member

lpinca commented May 17, 2026

Duplicate of #63100.

@trivikr trivikr closed this May 17, 2026
@trivikr trivikr deleted the flaky-test-performance-eventloopdelay branch May 17, 2026 20:11
@trivikr
Copy link
Copy Markdown
Member Author

trivikr commented May 17, 2026

Added request-ci label for #63100, so that it can be merged

@codecov
Copy link
Copy Markdown

codecov Bot commented May 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.05%. Comparing base (a9b0a83) to head (8675445).
⚠️ Report is 5 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #63387      +/-   ##
==========================================
- Coverage   90.06%   90.05%   -0.02%     
==========================================
  Files         714      714              
  Lines      225629   225648      +19     
  Branches    42702    42698       -4     
==========================================
- Hits       203211   203202       -9     
+ Misses      14232    14224       -8     
- Partials     8186     8222      +36     

see 64 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-ci PRs that need a full CI run. test Issues and PRs related to the tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants