Open Bug 1632270 Opened 6 years ago Updated 1 year ago

unhandledrejection doesn't work correctly in content scripts

Categories

(Core :: DOM: Core & HTML, defect, P3)

75 Branch
defect

Tracking

()

UNCONFIRMED

People

(Reporter: miika9764, Unassigned)

Details

Attachments

(1 file)

1.83 KB, application/zip
Details
Attached file files.zip

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:75.0) Gecko/20100101 Firefox/75.0

Steps to reproduce:

Actual results:

Got the alert
"Caught unhandledrejection in extension: ReferenceError: somethingStupid is not defined"
and the text
"Received unhandledrejection: ReferenceError: somethingStupid is not defined"
to the page when clicking "Trigger unhandledrejection", but nothing from the "Trigger unhandledrejection from extension" button.

Expected results:

I shouldn't have gotten an alert from the first button, and the second button should have alerted "Caught unhandledrejection in extension: unhandledrejection from extension". For example Chrome behaves this way.

Component: Untriaged → DOM: Core & HTML
Product: Firefox → Core
Flags: needinfo?(echen)
Severity: normal → S3
Priority: -- → P3
Flags: needinfo?(echen)

The same bug exists for the "error" event listener as well.

Tested on Firefox 134.0 (aarch64)

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: