Skip to content

test: mark hr-time WPT flaky on macos15-x64#64054

Open
trivikr wants to merge 1 commit into
nodejs:mainfrom
trivikr:wpt-test-hr-time
Open

test: mark hr-time WPT flaky on macos15-x64#64054
trivikr wants to merge 1 commit into
nodejs:mainfrom
trivikr:wpt-test-hr-time

Conversation

@trivikr

@trivikr trivikr commented Jun 22, 2026

Copy link
Copy Markdown
Member

This marks the hr-time WPT basic.any.js relative magnitude subtest as
flaky only on macos15-x64.

The subtest compares elapsed performance.now() with elapsed Date.now()
over a 2 second timeout. On macos15-x64 CI, Date.now() can shift relative
to Node's monotonic performance.now() clock enough to exceed the test's
30 ms tolerance.

The status file is converted from JSON to CJS so the flaky expectation can
be scoped to Darwin 24 on x64.

Refs: https://github.com/nodejs/reliability/issues?q=sort%3Aupdated-desc%20is%3Aissue%20state%3Aopen%20%22wpt%2Ftest-hr-time%22

Example
not ok 5757 wpt/test-hr-time
  ---
  duration_ms: 2313.94500
  severity: fail
  exitcode: 1
  stack: |-
    [SKIPPED] idlharness-shadowrealm.window.js: ShadowRealm support is not enabled
    [SKIPPED] window-worker-timeOrigin.window.js: depends on URL.createObjectURL(blob)
    [PASS] self.performance.now() is a function that returns a number
    [PASS] self.performance.now() returns a positive number
    [PASS] self.performance.now() difference is not negative
    [PASS] Performance interface extends EventTarget.
    [PASS] self.performance.now() returns a positive number
    [PASS] self.performance.now() difference is not negative
    [PASS] idl_test validation
    [PASS] Partial interface mixin WindowOrWorkerGlobalScope: original interface mixin defined
    [PASS] Partial interface mixin WindowOrWorkerGlobalScope: member names are unique
    [PASS] Partial interface Window: member names are unique
    [PASS] Window includes GlobalEventHandlers: member names are unique
    [PASS] Window includes WindowEventHandlers: member names are unique
    [PASS] Window includes WindowOrWorkerGlobalScope: member names are unique
    [PASS] WorkerGlobalScope includes WindowOrWorkerGlobalScope: member names are unique
    [PASS] Window includes AnimationFrameProvider: member names are unique
    [PASS] Window includes WindowSessionStorage: member names are unique
    [PASS] Window includes WindowLocalStorage: member names are unique
    [PASS] Performance interface: existence and properties of interface object
    [PASS] Performance interface object length
    [PASS] Performance interface object name
    [PASS] Performance interface: existence and properties of interface prototype object
    [PASS] Performance interface: existence and properties of interface prototype object's "constructor" property
    [PASS] Performance interface: existence and properties of interface prototype object's @@unscopables property
    [PASS] Performance interface: operation now()
    [PASS] Performance interface: operation toJSON()
    [PASS] Performance must be primary interface of performance
    [PASS] Stringification of performance
    [PASS] Performance interface: performance must inherit property "now()" with the proper type
    [PASS] Performance interface: performance must inherit property "timeOrigin" with the proper type
    [PASS] Performance interface: performance must inherit property "toJSON()" with the proper type
    [PASS] Performance interface: default toJSON operation on performance
    [EXPECTED_FAILURE][FAIL] Window interface: attribute performance
    assert_throws_js: calling getter on wrong object type must throw TypeError function "function () { [native code] }" did not throw
        at IdlInterface.do_interface_attribute_asserts (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/idlharness.js:3079:17)
        at IdlInterface.<anonymous> (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/idlharness.js:2221:18)
        at Test.step (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/testharness.js:2869:25)
        at IdlInterface.test_member_attribute (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/idlharness.js:2170:12)
    Command: /Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/out/Release/node  /Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/wpt/test-hr-time.js 'idlharness.any.js'
    
    [PASS] Window interface: self must inherit property "performance" with the proper type
    [PASS] Performance interface: attribute timeOrigin
    [PASS] idl_test setup
    [UNEXPECTED_FAILURE][FAIL] High resolution time has approximately the right relative magnitude
    assert_approx_equals: High resolution time value increased by approximately the same amount as time from date object expected 1955 +/- 30 but got 2000.2833889999997
        at Test.<anonymous> (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/hr-time/basic.any.js:25:5)
        at Test.<anonymous> (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/testharness.js:2990:25)
        at Test.step (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/testharness.js:2869:25)
        at Timeout._onTimeout (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/fixtures/wpt/resources/testharness.js:2916:35)
        at listOnTimeout (node:internal/timers:605:17)
    Command: /Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/out/Release/node  /Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/wpt/test-hr-time.js 'basic.any.js'
    
    
    {
      "basic.any.js": {
        "fail": {
          "unexpected": [
            "High resolution time has approximately the right relative magnitude"
          ]
        }
      },
      "idlharness-shadowrealm.window.js": {
        "skip": "ShadowRealm support is not enabled"
      },
      "idlharness.any.js": {
        "fail": {
          "expected": [
            "Window interface: attribute performance"
          ]
        }
      },
      "window-worker-timeOrigin.window.js": {
        "skip": "depends on URL.createObjectURL(blob)"
      }
    }
    
    Files: 3/5 ran, 1 passed, 2 skipped, 1 expected failure, 1 unexpected failure, 0 unexpected passes
    Subtests: 34 passed, 0 skipped, 1 expected failure, 1 unexpected failure, 0 unexpected passes
    /Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/common/wpt.js:844
            throw new Error(
            ^
    
    Error: Found 1 unexpected failures. Consider updating test/wpt/status/hr-time.json for these files:
    basic.any.js
        at process.<anonymous> (/Users/admin/build/workspace/node-test-commit-osx/nodes/macos15-x64/test/common/wpt.js:844:15)
        at process.emit (node:events:509:20)

The basic.any.js test compares elapsed performance.now() with elapsed
Date.now(). On macos15-x64 CI, Date.now() can shift relative to the
monotonic clock and exceed the test's 30 ms tolerance.

Convert the status file to .cjs so the flaky expectation is scoped to
macOS 15 on x64.

Signed-off-by: Kamat, Trivikram <16024985+trivikr@users.noreply.github.com>
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/web-standards

@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 Jun 22, 2026
@trivikr trivikr added flaky-test Issues and PRs related to the tests with unstable failures on the CI. request-ci Add this label to start a Jenkins CI on a PR. labels Jun 22, 2026

@mcollina mcollina left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm

@trivikr trivikr added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Jun 22, 2026
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Jun 22, 2026
@nodejs-github-bot

This comment was marked as outdated.

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

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

Labels

author ready PRs that have at least one approval, no pending requests for changes, and a CI started. flaky-test Issues and PRs related to the tests with unstable failures on the CI. 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.

5 participants