Closed Bug 1140286 Opened 9 years ago Closed 7 years ago

Intermittent e10s browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - Error: operation not possible on dead CPOW at :0

Categories

(Toolkit :: General, defect, P5)

x86
Linux
defect

Tracking

()

RESOLVED FIXED
mozilla51
Tracking Status
e10s + ---
firefox49 --- wontfix
firefox50 --- fixed
firefox51 --- fixed

People

(Reporter: cbook, Assigned: kevchan85, Mentored)

References

(Blocks 1 open bug, )

Details

(Keywords: intermittent-failure)

Attachments

(1 file, 4 obsolete files)

Ubuntu ASAN VM 12.04 x64 mozilla-inbound opt test mochitest-e10s-browser-chrome-3

https://treeherder.mozilla.org/logviewer.html#?job_id=7284474&repo=mozilla-inbound

23:04:17 INFO - 94 INFO TEST-UNEXPECTED-FAIL | toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - uncaught exception: undefined at :0
Summary: Intermittent browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - uncaught exception: undefined at :0 → Intermittent browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - Error: operation not possible on dead CPOW at :0
Summary: Intermittent browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - Error: operation not possible on dead CPOW at :0 → Intermittent e10s browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - Error: operation not possible on dead CPOW at :0
Blocks: e10s-tests
tracking-e10s: --- → +
Intermittent e10s test failure
Priority: -- → P5
08:45:36     INFO -  417 INFO TEST-UNEXPECTED-FAIL | toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js | uncaught exception - Error: operation not possible on dead CPOW at getContentDocument@resource://gre/modules/RemoteAddonsParent.jsm:880:3
08:45:36     INFO -  RemoteBrowserElementInterposition.getters.contentDocument@resource://gre/modules/RemoteAddonsParent.jsm:897:10
08:45:36     INFO -  AddonInterpositionService.prototype.interposeProperty/desc.get@resource://gre/components/multiprocessShims.js:165:38
08:45:36     INFO -  runTests@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js:24:3
08:45:36     INFO -  TestRunner.next@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/head.js:58:15
08:45:36     INFO -  next@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/head.js:81:3
08:45:36     INFO -  testScope/test_executeSoon/<.run@chrome://mochikit/content/browser-test.js:993:9
08:45:36     INFO -  Stack trace:
08:45:36     INFO -  chrome://mochikit/content/tests/SimpleTest/SimpleTest.js:simpletestOnerror:1609
08:45:36     INFO -  JavaScript error: resource://gre/modules/RemoteAddonsParent.jsm, line 880: Error: operation not possible on dead CPOW
08:45:36     INFO -  418 INFO Console message: [JavaScript Error: "Error: operation not possible on dead CPOW" {file: "resource://gre/modules/RemoteAddonsParent.jsm" line: 880}]
08:45:36     INFO -  getContentDocument@resource://gre/modules/RemoteAddonsParent.jsm:880:3
08:45:36     INFO -  RemoteBrowserElementInterposition.getters.contentDocument@resource://gre/modules/RemoteAddonsParent.jsm:897:10
08:45:36     INFO -  AddonInterpositionService.prototype.interposeProperty/desc.get@resource://gre/components/multiprocessShims.js:165:38
08:45:36     INFO -  runTests@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js:24:3
08:45:36     INFO -  TestRunner.next@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/head.js:58:15
08:45:36     INFO -  next@chrome://mochitests/content/browser/toolkit/components/thumbnails/test/head.js:81:3
08:45:36     INFO -  testScope/test_executeSoon/<.run@chrome://mochikit/content/browser-test.js:993:9
Kevin, interested in looking at this one? :)
Flags: needinfo?(kechen)
Hi Ryan,

Not sure if I am the right person for this bug, I am not really familiar with this part of codes.

Maybe Kanru is the one you are looking for? There is only one character difference between our email. lol

I will still try to investigate it if no one is working on this after I finish my current tasks.
Flags: needinfo?(kechen)
Wrong Kevin :)
Flags: needinfo?(kevchan85)
Good Morning!

So I have looked at the code... is it here? 

isnot(browser.contentDocument.documentElement.style.backgroundColor,
        redStr,
        "The page shouldn't be red.");
Flags: needinfo?(kevchan85) → needinfo?(ryanvm)
Yes, that looks like the one. Looks like browser_thumbnails_bg_no_cookies_sent.js in the same directory had similar issues and the answer was to use ContentTask instead. I'm guessing that's probably the right fix for this test too. Is that right, Drew?

https://hg.mozilla.org/mozilla-central/rev/672c62e62034
Flags: needinfo?(ryanvm) → needinfo?(adw)
Yeah, getting rid of all CPOW usage by using content scripts should fix this.  The revision you linked to, Ryan, should be a good template for fixing this.  kevin, if you're working on this, let me know if you have any questions.
Flags: needinfo?(adw)
Attached patch bug1254867_intermittent_e10.diff (obsolete) — Splinter Review
Hello Ryan,

Is this right? I tested it and it passed on my side.
Attachment #8790413 - Flags: review?(ryanvm)
Oops wrong file sorry
Attachment #8790413 - Attachment is obsolete: true
Attachment #8790413 - Flags: review?(ryanvm)
Comment on attachment 8790413 [details] [diff] [review]
bug1254867_intermittent_e10.diff

Looks like you attached the wrong patch. Also, please request review from Drew as I'm not an eligible reviewer for this code.
Attachment #8790414 - Flags: review?(adw)
Comment on attachment 8790414 [details] [diff] [review]
bug1140286_Removed_CPOW_Usage.diff

Review of attachment 8790414 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good but there's one more change to make.

::: toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js
@@ +15,4 @@
>    removeThumbnail(url);
>    // now load it up in a browser - it should *not* be red, otherwise the
>    // cookie above was saved.
>    let tab = gBrowser.loadOneTab(url, { inBackground: false });

Please replace this line with

let tab = yield BrowserTestUtils.openNewForegroundTab(gBrowser, url);

and remove the `yield whenLoaded(browser)` line a couple of lines below.
Attachment #8790414 - Flags: review?(adw)
Assignee: nobody → kevchan85
Mentor: adw
Status: NEW → ASSIGNED
I updated the file, is this what you meant?
Attachment #8790475 - Flags: review?(adw)
Attachment #8790414 - Attachment is obsolete: true
Comment on attachment 8790475 [details] [diff] [review]
bug1140286_Removed_CPOW_Usage.diff

Review of attachment 8790475 [details] [diff] [review]:
-----------------------------------------------------------------

Yes, thanks.
Attachment #8790475 - Flags: review?(adw) → review+
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/fx-team/rev/124402b3d833
Remove CPOW usage from browser_thumbnails_bg_no_cookies_stored.js. r=adw
kevin, it looks like you misspelled openNewForegroundTab:

+  let tab = yield BrowserTestUtils.openNewForgroundTab(gBrowser, url);

Error message from a failing log:

 04:21:52 INFO - 303 INFO Console message: [JavaScript Error: "BrowserTestUtils.openNewForgroundTab is not a function" {file: "chrome://mochitests/content/browser/toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js" line: 18}] 

You can see the correct full line in comment 84.

Could you please fix it, make sure that the test works on your computer, and post a new patch?
Flags: needinfo?(kevchan85)
Hello

Here is the update!
Attachment #8790475 - Attachment is obsolete: true
Flags: needinfo?(kevchan85)
Attachment #8790852 - Flags: review?(adw)
Comment on attachment 8790852 [details] [diff] [review]
bug1140286_Removed_CPOW_Usage.diff

Review of attachment 8790852 [details] [diff] [review]:
-----------------------------------------------------------------

::: toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_stored.js
@@ +20,3 @@
>  
>    // The root element of the page shouldn't be red.
> +  yield ContentTask.spawn(browser, null, function(){

Phil had to push a follow-up lint fix for this line, so to prevent that again, please add a space between `function` and the opening paren, like his commit did:

https://hg.mozilla.org/integration/fx-team/rev/2883c2d21815
Attachment #8790852 - Flags: review?(adw)
Hello so did you want function to be like this function (){
or function() {. 

The link has the second one... but you say parenthesis. I just want to make sure
Flags: needinfo?(adw)
Sorry, like the link, yes.  Between the () and the {.

+  yield ContentTask.spawn(browser, null, function() {
Flags: needinfo?(adw)
Here is the update. Let me know if there is anything else!
Attachment #8791001 - Flags: review?(adw)
Comment on attachment 8791001 [details] [diff] [review]
bug1140286_Removed_CPOW_Usage.diff

Review of attachment 8791001 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks, should be good now.
Attachment #8791001 - Flags: review?(adw) → review+
Attachment #8790852 - Attachment is obsolete: true
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/fx-team/rev/181fa71d8b01
Remove CPOW usage from browser_thumbnails_bg_no_cookies_stored.js. r=adw
https://hg.mozilla.org/mozilla-central/rev/181fa71d8b01
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
You need to log in before you can comment on or make changes to this bug.