Closed Bug 574941 Opened 14 years ago Closed 13 years ago

Errors within events triggered by .dispatchEvent are not shown in the Error Console

Categories

(Core :: XPConnect, defect)

defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 503244

People

(Reporter: jorisvdwel, Unassigned)

References

()

Details

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.4) Gecko/20100611 Firefox/3.6.4
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.4) Gecko/20100611 Firefox/3.6.4

When an event is triggered by Node.dispatchEvent, any errors within that event are not shown in the Error Console or in firebug. They do however, show up in venkman (if I recall correctly venkman shows exceptions even if they are caught by try... catch).

Reproducible: Always

Steps to Reproduce:
1. Open the attached test case
2. Open the Error Console
3. Press "Trigger Error"
4. Press "Trigger Error (dispatchEvent)"
Actual Results:  
3. An alert is displayed AND an error is shown in the error console
4. An alert is displayed, but no error in the error console

Expected Results:  
4. Should display an alert AND an error in the error console
Attached file Test Case
Sounds like the usual XPConnect eating the exception when calling into a JS-implemented component (nsIDOMEventListener in this case) with JS on the stack....
Component: DOM: Events → XPConnect
QA Contact: events → xpconnect
Whiteboard: DUPEME
Just bumped into this issue yesterday. It still affects Firefox 4 nightly builds. I tested with Ubuntu Linux 64 bits, so I presume this issue is cross-platform.
Confirming per comment 3.
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows XP → All
Hardware: x86 → All
Version: unspecified → Trunk
I don't know if this is important, but this is true for "throw"s as well as errors. Replace both "obj.bla.def = 5;" lines with "throw new Error('this is an error')" and the bug still occurs.
This is a duplicate of #503244
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → DUPLICATE
Whiteboard: DUPEME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: