Closed Bug 913950 Opened 6 years ago Closed 6 years ago

frameworker error message

Categories

(Firefox Graveyard :: SocialAPI, defect)

26 Branch
defect
Not set

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 26

People

(Reporter: mixedpuppy, Assigned: markh)

References

Details

Attachments

(1 file)

On the UX branch I see several of these messages dumped into the console.  

A coding exception was thrown in a Promise resolution callback.
Full message: TypeError: browser.messageManager is undefined
See https://developer.mozilla.org/Mozilla/JavaScript_code_modules/Promise.jsm/Promise
Full stack: ParentPort.prototype._dopost/<@resource://gre/modules/FrameWorker.jsm:162
Handler.prototype.process@resource://gre/modules/Promise.jsm:572
@resource://gre/modules/Promise.jsm:354

I have only the demo provider enabled.  allowMultipleWorkers=true.  Happens on startup, as well as each time I reload the provider via the context menu.  Everything seems to work otherwise (basic manual testing using the demo provider).
This error is from ports being closed after the worker terminates (in this specific case, it looks like something to do with social.cookies-get, which seems be be called multiple times per second in the demo provider?)

We should be closing all worker ports we have handed out as the worker terminates - then the ports will all be closed, so attempts to use them after the terminate will either silently do nothing (on another .close()) or throw a more reasonable error if a real message is posted.

This patch seems to silence the errors I saw and seems to be the "right thing" to do.
Assignee: nobody → mhammond
Status: NEW → ASSIGNED
Attachment #801322 - Flags: review?(mixedpuppy)
Duplicate of this bug: 914400
Comment on attachment 801322 [details] [diff] [review]
0001-Bug-913950-close-all-existing-ports-on-worker-termin.patch

LGTM
Attachment #801322 - Flags: review?(mixedpuppy) → review+
https://hg.mozilla.org/integration/fx-team/rev/41539c7111e0
OS: Mac OS X → All
Hardware: x86 → All
https://hg.mozilla.org/mozilla-central/rev/41539c7111e0
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 26
Product: Firefox → Firefox Graveyard
You need to log in before you can comment on or make changes to this bug.