Closed Bug 2081288 Opened 1 month ago Closed 27 days ago

High frequency docshell/base/crashtests/2075414.html | single tracking bug

Categories

(Testing :: Reftest, defect, P5)

defect

Tracking

(firefox-esr153 unaffected, firefox158 unaffected, firefox159 unaffected, firefox160 fixed, firefox161 fixed)

RESOLVED FIXED
161 Branch
Tracking Status
firefox-esr153 --- unaffected
firefox158 --- unaffected
firefox159 --- unaffected
firefox160 --- fixed
firefox161 --- fixed

People

(Reporter: intermittent-bug-filer, Assigned: dholbert)

References

(Regression)

Details

(Keywords: intermittent-failure, intermittent-testcase, regression, Whiteboard: [collect_confirm_failure])

Attachments

(2 external files, 1 obsolete file)

Filed by: sstanca [at] mozilla.com
Parsed log: https://treeherder.mozilla.org/logviewer?job_id=599456344&repo=autoland&task=OyyZvdttSSqqHZwTCngT7A.0
Full log: https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/OyyZvdttSSqqHZwTCngT7A/runs/0/artifacts/public/logs/live_backing.log
Reftest URL: https://hg.mozilla.org/mozilla-central/raw-file/default/layout/tools/reftest/reftest-analyzer.xhtml#logurl=https://firefox-ci-tc.services.mozilla.com/api/queue/v1/task/OyyZvdttSSqqHZwTCngT7A/runs/0/artifacts/public/logs/live_backing.log&only_show_unexpected=1


[task 2026-10-13T14:19:39.353+00:00] 14:19:39     INFO - REFTEST TEST-PASS | docshell/base/crashtests/ifr-overrecursion-load.html | (LOAD ONLY)
[task 2026-10-13T14:19:39.354+00:00] 14:19:39     INFO - REFTEST TEST-END | docshell/base/crashtests/ifr-overrecursion-load.html
[task 2026-10-13T14:19:39.389+00:00] 14:19:39     INFO - REFTEST TEST-START | docshell/base/crashtests/2075414.html
[task 2026-10-13T14:19:39.390+00:00] 14:19:39     INFO - REFTEST TEST-LOAD | file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html | 2522 / 4245 (59%)
[taskcluster 2026-10-13T14:23:12.947Z] [taskcluster-proxy] Successfully refreshed taskcluster-proxy credentials: task-client/OyyZvdttSSqqHZwTCngT7A/0/on/us-east1-d/7443115182385235037/until/1791902592.879
[task 2026-10-13T14:24:39.399+00:00] 14:24:39     INFO - REFTEST TEST-UNEXPECTED-FAIL | docshell/base/crashtests/2075414.html | load failed: timed out waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.401+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: START file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.402+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] OnDocumentLoad triggering WaitForTestEnd
[task 2026-10-13T14:24:39.402+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] WaitForTestEnd: Adding listeners
[task 2026-10-13T14:24:39.403+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Initializing canvas snapshot
[task 2026-10-13T14:24:39.403+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] OnDocumentLoad fired for previous document
[task 2026-10-13T14:24:39.404+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.404+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_TO_FIRE_INVALIDATE_EVENT
[task 2026-10-13T14:24:39.405+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: dispatching MozReftestInvalidate
[task 2026-10-13T14:24:39.405+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.406+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.406+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:blank
[task 2026-10-13T14:24:39.407+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_FOR_REFTEST_WAIT_REMOVAL
[task 2026-10-13T14:24:39.407+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.408+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] HandlePendingTasksAfterMakeProgress updating canvas
[task 2026-10-13T14:24:39.408+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] Sending update whole canvas for invalidation
[task 2026-10-13T14:24:39.409+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Updating entire canvas for invalidation
[task 2026-10-13T14:24:39.409+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.410+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] OnDocumentLoad triggering WaitForTestEnd
[task 2026-10-13T14:24:39.410+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_FOR_REFTEST_WAIT_REMOVAL
[task 2026-10-13T14:24:39.411+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.411+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] WaitForTestEnd: Adding listeners
[task 2026-10-13T14:24:39.412+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Initializing canvas snapshot
[task 2026-10-13T14:24:39.412+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.413+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.413+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.413+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.414+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.414+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.415+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_TO_FIRE_INVALIDATE_EVENT
[task 2026-10-13T14:24:39.415+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for updateCanvasPending
[task 2026-10-13T14:24:39.416+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] HandlePendingTasksAfterMakeProgress updating canvas
[task 2026-10-13T14:24:39.416+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] Sending update whole canvas for invalidation
[task 2026-10-13T14:24:39.417+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Updating entire canvas for invalidation
[task 2026-10-13T14:24:39.417+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.418+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] HandlePendingTasksAfterMakeProgress updating canvas
[task 2026-10-13T14:24:39.418+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] Sending update whole canvas for invalidation
[task 2026-10-13T14:24:39.419+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.419+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Updating entire canvas for invalidation
[task 2026-10-13T14:24:39.420+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.420+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] OnDocumentLoad fired for previous document
[task 2026-10-13T14:24:39.421+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_FOR_REFTEST_WAIT_REMOVAL
[task 2026-10-13T14:24:39.421+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.422+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.423+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.423+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.423+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.424+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.425+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] HandlePendingTasksAfterMakeProgress updating canvas
[task 2026-10-13T14:24:39.425+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] SendUpdateCanvasForEvent with 0 rects
[task 2026-10-13T14:24:39.426+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.426+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Updating canvas for invalidation
[task 2026-10-13T14:24:39.427+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.427+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_FOR_REFTEST_WAIT_REMOVAL
[task 2026-10-13T14:24:39.428+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.428+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.429+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in file:///builds/worker/workspace/build/tests/reftest/tests/docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.429+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.430+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] AfterPaintListener in about:srcdoc
[task 2026-10-13T14:24:39.431+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.431+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] HandlePendingTasksAfterMakeProgress updating canvas
[task 2026-10-13T14:24:39.432+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] Sending update whole canvas for invalidation
[task 2026-10-13T14:24:39.432+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] FromChildAfterPaintListener from about:srcdoc
[task 2026-10-13T14:24:39.433+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: Updating entire canvas for invalidation
[task 2026-10-13T14:24:39.433+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress
[task 2026-10-13T14:24:39.434+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: STATE_WAITING_FOR_REFTEST_WAIT_REMOVAL
[task 2026-10-13T14:24:39.434+00:00] 14:24:39     INFO - REFTEST INFO | Saved log: [CONTENT] MakeProgress: waiting for reftest-wait to be removed
[task 2026-10-13T14:24:39.435+00:00] 14:24:39     INFO - REFTEST TEST-END | docshell/base/crashtests/2075414.html
[task 2026-10-13T14:24:39.490+00:00] 14:24:39     INFO - REFTEST TEST-START | dom/xhr/tests/crashtests/1546185.html
[task 2026-10-13T14:24:39.491+00:00] 14:24:39     INFO - REFTEST TEST-LOAD | file:///builds/worker/workspace/build/tests/reftest/tests/dom/xhr/tests/crashtests/1546185.html | 2523 / 4245 (59%)
[task 2026-10-13T14:24:39.580+00:00] 14:24:39     INFO - JavaScript error: file:///builds/worker/workspace/build/tests/reftest/tests/dom/xhr/tests/crashtests/1546185.html, line 33: EncodingError: The buffer passed to decodeAudioData contains an unknown content type.
[task 2026-10-13T14:24:39.619+00:00] 14:24:39     INFO - REFTEST TEST-PASS | dom/xhr/tests/crashtests/1546185.html | (LOAD ONLY)
[task 2026-10-13T14:24:39.619+00:00] 14:24:39     INFO - REFTEST TEST-END | dom/xhr/tests/crashtests/1546185.html

When a reftest-wait test reloads itself (e.g. docshell/base/crashtests/2075414.html), the harness gets a second OnDocumentLoad and starts a second WaitForTestEnd, while the first one stays active waiting on the old document, which still has reftest-wait set and is kept alive.

Both instances share gUpdateCanvasPromiseResolver. If the stale instance sends a canvas update while the live one's update is in flight, it overwrites the resolver. The live instance's promise then never resolves, so it hangs with an operation in progress, and the stale instance keeps reporting "timed out waiting for reftest-wait to be removed".

Fix: in OnDocumentLoad for the current test, tear down any still-active WaitForTestEnd via gTimeoutHook (RemoveListeners). HandlePendingTasksAfterMakeProgress also bails out once the instance is completed, so a torn-down instance can't send more canvas updates from in-flight callbacks.

Hey Dan, can I ask you to take a look at the proposed patch for this super-frequent orange or redirect it to someone else? Thanks!

Component: DOM: Navigation → Reftest
Flags: needinfo?(dholbert)
Product: Core → Testing

Happy to take a look once phab is cooperating -- right now I can't view the diff (even on internal VPN).

So this is a case where a reftest-wait reftest is reloading itself (fortunately in a way that's limited to only happen once, since the test detects the post-reload state with performance.getEntriesByType("navigation")[0].type).

I don't think that's a situation that the reftest harness is designed to robustly handle. The patch seems like a reasonable band-aid to avoid catastrophically failing, but I'm not confident that it won't just result in more/different badness, either with this test or other tests.

Really, it feels like a better/more-robust approach would be to rewrite the test to do its work in an iframe (which can reload itself), and then when the iframe is done, we can remove reftest-wait in the outer frame. That's traditionally how we've handled this sort of situation (where we have a reftest-wait test that needs to do navigation of any sort).

Flags: needinfo?(dholbert)

Before this patch, the crashtest 2075414.html reloads itself, which is not
something that the reftest harness robustly handles (particularly for
"reftest-wait" tests). When a test needs to do that, we typically handle it by
putting put the main guts of the test an iframe which can freely navigatee,
which gets hosted by a lightweight outer document that waits for a signal from
the inner document before declaring the test done.

This patch does that for this crashtest -- just moving the existing crashtest
to now be 2075414-frame.html, and creating a new lightweight 2075414.html to
host it in an iframe and maintain the "reftest-wait" is-the-test-done state.

Assignee: nobody → dholbert
Status: NEW → ASSIGNED

(marking as a regression from bug 2075414, which is the bug that added this test; I think this has been an issue since the test was added.)

Keywords: regression
Regressed by: 2075414
Attachment #9666329 - Attachment is obsolete: true

Set release status flags based on info from the regressing bug 2075414

Set release status flags based on info from the regressing bug 2075414

Hi, I see that the patch is accepted, is it ok if I land it?

Flags: needinfo?(dholbert)
Summary: Intermittent docshell/base/crashtests/2075414.html | single tracking bug → High frequency docshell/base/crashtests/2075414.html | single tracking bug

(In reply to Goloman Adrian[:agoloman] from comment #22)

Hi, I see that the patch is accepted, is it ok if I land it?

Hi! Sorry, I overlooked the r+ and forgot about this bug. I've triggered lando, so the patch should be landing shortly.

Flags: needinfo?(dholbert)
Status: ASSIGNED → RESOLVED
Closed: 27 days ago
Resolution: --- → FIXED
Target Milestone: --- → 161 Branch

The patch landed in nightly and beta is affected.

:dholbert, please make an uplift decision for beta:

  • For beta, nominate the patch for beta uplift approval if the fix should be included in this release, or set status-firefox160 to wontfix if the fix can wait for the next release.

Uplift requests can be submitted from Lando: D336047.

See Requesting an Uplift for documentation on how to request an uplift.

For more information, please visit BugBot documentation.

Flags: needinfo?(dholbert)

firefox-beta Uplift Approval Request

  • User impact if declined/Reason for urgency: No user impact; this is just making a flaky test less flaky.
  • Code covered by automated testing?: yes
  • Fix verified in Nightly?: yes
  • Needs manual QE testing?: no
  • Steps to reproduce for manual QE testing:
  • Risk associated with taking this patch: low
  • Explanation of risk level: Just modifying an automated test.
  • String changes made/needed?: None
  • Is Android affected?: yes
Attachment #9673552 - Flags: approval-mozilla-beta?

Before this patch, the crashtest 2075414.html reloads itself, which is not
something that the reftest harness robustly handles (particularly for
"reftest-wait" tests). When a test needs to do that, we typically handle it by
putting put the main guts of the test an iframe which can freely navigate,
which gets hosted by a lightweight outer document that waits for a signal from
the inner document before declaring the test done.

This patch does that for this crashtest -- just moving the existing crashtest
to now be 2075414-frame.html, and creating a new lightweight 2075414.html to
host it in an iframe and maintain the "reftest-wait" is-the-test-done state.

Original Revision: https://phabricator.services.mozilla.com/D336047

Flags: needinfo?(dholbert)
Attachment #9673552 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Whiteboard: [qa-triage-done-c161/b160]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: