If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

gBrowser.addProgressListener call with a 2nd argument throws uninformative error

RESOLVED FIXED in Firefox 26

Status

()

Firefox
General
RESOLVED FIXED
6 years ago
4 years ago

People

(Reporter: Sean Newman, Assigned: dao)

Tracking

({regression})

9 Branch
Firefox 26
regression
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

6 years ago
When gBrowser.addProgressListener gets called with 2nd argument, we get an uninformative error in the error console:

Error: gBrowser.addProgressListener was called with a second argument, which is not supported. See bug 608628.
Source File: chrome://browser/content/tabbrowser.xml
Line: 1871

How am I supposed to know who was the caller?

var caller = Components.stack.caller;
throw new Error(
	"...",
	caller.filename,
	caller.lineNumber
);

or Components.utils.reportError(new Error( ... ));
(Reporter)

Updated

6 years ago
Blocks: 608628
(Assignee)

Comment 1

6 years ago
NS_ASSERT actually displays the stack in non-release builds:
http://mxr.mozilla.org/mozilla-central/source/toolkit/content/debug.js#95
(Reporter)

Comment 2

6 years ago
But couldn't you make that error itself in the error console be more informative and make it tell who was the caller?
(Reporter)

Comment 3

6 years ago
How I'm tired of these errors!
Error: gBrowser.addProgressListener was called with a second argument, which is not supported. See bug 608628.
Source File: chrome://browser/content/tabbrowser.xml
Line: 1877

And how the f- do I get know who called that gBrowser.addProgressListener with a f-ing second argument? How am I supposed to investigate that f-ing error?
Why this bug is still UNCO?
(Reporter)

Comment 4

6 years ago
bump

Comment 5

4 years ago
There's still no meaningful error message for this. Took me half an hour to find out which extension caused this error. Playing the "half enabled, half disabled"-game with 50+ extension is really funny...
(Assignee)

Updated

4 years ago
Blocks: 644645
No longer blocks: 608628
Keywords: regression
(Assignee)

Updated

4 years ago
Blocks: 905477
(Assignee)

Updated

4 years ago
Severity: major → normal
(Assignee)

Comment 6

4 years ago
Created attachment 791314 [details] [diff] [review]
patch
Assignee: nobody → dao
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Attachment #791314 - Flags: review?(gavin.sharp)
Attachment #791314 - Flags: review?(gavin.sharp) → review+
(Assignee)

Comment 7

4 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/541db4a9ecbe
https://hg.mozilla.org/mozilla-central/rev/541db4a9ecbe
Status: ASSIGNED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 26
You need to log in before you can comment on or make changes to this bug.