Closed Bug 1396652 Opened 7 years ago Closed 7 years ago

Intermittent toolkit/components/extensions/test/mochitest/test_ext_xhr_capabilities.html | application crashed [@ WebRequestService::ChannelParent::Detach()]

Categories

(WebExtensions :: General, defect, P5)

defect

Tracking

(firefox-esr52 unaffected, firefox55 unaffected, firefox56 unaffected, firefox57 verified)

VERIFIED FIXED
mozilla57
Tracking Status
firefox-esr52 --- unaffected
firefox55 --- unaffected
firefox56 --- unaffected
firefox57 --- verified

People

(Reporter: intermittent-bug-filer, Assigned: kmag)

Details

(Keywords: crash, intermittent-failure)

Crash Data

Attachments

(1 file, 1 obsolete file)

Assignee: nobody → kmaglione+bmo
Comment on attachment 8904356 [details]
Bug 1396652: Ensure ordered destruction of channel entries at shutdown.

https://reviewboard.mozilla.org/r/176150/#review181138
Attachment #8904356 - Flags: review?(mixedpuppy) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/cdecd701b70f219f9d60731418ce20eb0d3761fd
Bug 1396652: Ensure ordered destruction of channel entries at shutdown. r=mixedpuppy
https://hg.mozilla.org/mozilla-central/rev/cdecd701b70f
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
I just hit this again on a Try push that was off m-c tip (including the merge from comment 4) :(. These are on 57-as-Beta Try simulations in case that ends up mattering.

https://treeherder.mozilla.org/logviewer.html#?job_id=128718969&repo=try
Status: RESOLVED → REOPENED
Flags: needinfo?(kmaglione+bmo)
Resolution: FIXED → ---
Target Milestone: mozilla57 → ---
If you want to replicate the build config, the patch below should suffice.
https://hg.mozilla.org/try/rev/bfe9a997b897e23db1a899b46faa4a88a9e6b6e2
Hm. This is actually a slightly different error. It looks like what's happening is that we're clearing the cached service entry stored in GetSingleton() before the service is destroyed (because the final ClearOnShutdown phase happens before the XPCOM service manager is destroyed), so when we GetSingleton() to try to remove the entry we're destroying, it creates a new instance, which has nothing stored in its maps.
Flags: needinfo?(kmaglione+bmo)
Attachment #8904356 - Attachment is obsolete: true
Comment on attachment 8905747 [details]
Bug 1396652: Fix WebRequestService destructor ordering issue.

With this patch applied, the failures turn into:
https://treeherder.mozilla.org/logviewer.html#?job_id=129417380&repo=try
Flags: needinfo?(kmaglione+bmo)
Attachment #8905747 - Flags: feedback-
(In reply to Ryan VanderMeulen [:RyanVM] from comment #9)
> Comment on attachment 8905747 [details]
> Bug 1396652: Fix WebRequestService destructor ordering issue.
> 
> With this patch applied, the failures turn into:
> https://treeherder.mozilla.org/logviewer.html#?job_id=129417380&repo=try

Hm. So, that failure is because we're trying to remove entries while the parent frame is iterating over the hashtable. But, for some reason, I can't trigger that failure on Linux, even I intentionally leave a bunch of channels registered until shutdown. :(
Flags: needinfo?(kmaglione+bmo)
Comment on attachment 8905747 [details]
Bug 1396652: Fix WebRequestService destructor ordering issue.

https://reviewboard.mozilla.org/r/177548/#review182836
Attachment #8905747 - Flags: review?(mixedpuppy) → review+
Per comment 9, the patch that landed isn't going to fix the issue.
Keywords: leave-open
(In reply to Ryan VanderMeulen [:RyanVM] from comment #14)
> Per comment 9, the patch that landed isn't going to fix the issue.

The patch I landed in comment 10?
Ah, I missed that there was an update to the patch there. We'll see how it goes and I'll reopen the bug tomorrow if need-be.
Keywords: leave-open
https://hg.mozilla.org/mozilla-central/rev/c6425c1515d1
Status: REOPENED → RESOLVED
Closed: 7 years ago7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
Looks good indeed :)
Status: RESOLVED → VERIFIED
Product: Toolkit → WebExtensions
You need to log in before you can comment on or make changes to this bug.