Closed Bug 1735131 Opened 4 years ago Closed 4 years ago

(Puppeteer) JavaScript error: chrome://remote/content/cdp/observers/ContextObserver.jsm, line 137: TypeError: can't access property "docShell", window is null

Categories

(Remote Protocol :: CDP, defect, P2)

defect
Points:
2

Tracking

(firefox-esr78 unaffected, firefox-esr91 unaffected, firefox93 unaffected, firefox94 unaffected, firefox95 fixed)

RESOLVED FIXED
95 Branch
Tracking Status
firefox-esr78 --- unaffected
firefox-esr91 --- unaffected
firefox93 --- unaffected
firefox94 --- unaffected
firefox95 --- fixed

People

(Reporter: whimboo, Assigned: whimboo)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [bidi-m2-mvp])

Attachments

(1 file)

When I run several Puppeteer tests locally I can see the following Javascript error in the console:

JavaScript error: chrome://remote/content/cdp/observers/ContextObserver.jsm, line 137: TypeError: can't access property "docShell", window is null

It's coming from our context observer when handling the document-element-inserted notification.

Interestingly I do not see this failure when running our browser chrome tests.

The cases when the window is null are actually happening because Puppeteer tests are loading pages that contain a textarea. The other document that gets inserted and causes the notification to be fired here is a SVG, specifically the resizer for the textarea field with the URL: chrome://global/skin/icons/resizer.svg.

As such we have to ignore all the events that do not have a valid window attached.

Assignee: nobody → hskupin
Status: NEW → ASSIGNED

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

Points: --- → 2
Priority: -- → P2
Pushed by hskupin@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0c98c980f2de [remote] Ignore "document-element-inserted" notifications without a window object. r=webdriver-reviewers,jdescottes
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: