Closed Bug 1283704 Opened 4 years ago Closed 4 years ago
_bug812562 .js | Uncaught exception - at :0 - Error: operation not possible on dead CPOW
Probably here: http://searchfox.org/mozilla-central/rev/a7c8e9f3cc323fd707659175a46826ad12899cd1/browser/base/content/test/plugins/browser_bug812562.js#62 You can probably fix this by changing that to gTestBrowser.goBack();
Indeed! This could make a pretty nice good-first-bug.
Can I have information on how to test this particular module?
I can absolutely help you get started. First of all, do you have a build of Firefox ready to go? If not, let me know and I can guide you through that. If so, you can run the test in question using this command from within the repository directory: ./mach mochitest browser/base/content/test/plugins/browser_bug812562.js That should, after a few seconds, open up an instance of Firefox, run the test, and (if all goes well) close it all down. There will be a bunch of stuff spewed to the console, as well. This bug is about an intermittent failure, meaning that _sometimes_ (due to a timing issue) the test will fail, and sometimes it won't. Sometimes those failures will only occur on our test machines in automation, which is pretty frustrating if you're trying to fix the failure locally. So check to see if the test passes for you locally. If it doesn't - great! We can work with that. If it does, that's still okay - we can try the fix I suggest in the bug and push it to automation to see if it fixes it. The next step is to open the test file at browser/base/content/test/plugins/browser_bug812562.js, at the line I point at in the bug, and change the line I mentioned to just: gTestBrowser.goBack(); If you're interested in why this fixes the bug, it's because the old line: gTestBrowser.contentWindow.history.back(); is accessing the "contentWindow" property, which (when running with multi-process Firefox) uses our "CPOW" layer to synchronously message the content that's running in the other process. This usually works, but because CPOWs don't hold strong references to the things in the other processes, it means that if the content window in the other process disappears, then accessing gTestBrowser.contentWindow.anything will result in a "dead CPOW" error, meaning that the item in the other process has disappeared. Using gTestBrowser.goBack() avoids the CPOW, and uses a "message" instead to send the browser back, which should be safer. Give that a shot, and see if the test still passes for you locally. If it does, great! Attach your patch (which I can guide you through) to the bug (or use MozReview to post it), and we'll send it to automation to see if the intermittent has gone. I hope that helps! Let me know. Feel free to use the "needinfo" flag (towards the bottom of this page) on "mentor" to get my attention. : mikeconley.ca/blog/2015/02/17/on-unsafe-cpow-usage-in-firefox-desktop-and-why-is-my-nightly-so-sluggish-with-e10s-enabled/ : https://mozilla-version-control-tools.readthedocs.io/en/latest/mozreview-user.html
Hello! Thanks for the tips. Did I attach the patch correctly?
(In reply to kevin from comment #7) > Hello! > Thanks for the tips. Did I attach the patch correctly? You did indeed! I'll push this patch to try to see if the error has gone away. If so, I think we've got a winner.
Comment on attachment 8784668 [details] [diff] [review] bug1283704_intermittent_browser.diff I did a bunch of retriggers, and while I see some oranges, I don't see this one. Unfortunately, this one was rather rare, so I can't be absolutely sure we fixed it, but you _have_ removed a CPOW here, so I have pretty high confidence. Great work!
Attachment #8784668 - Flags: review?(mconley) → review+
Author: kevin <firstname.lastname@example.org> Bug number: 1283704 Commit message: Bug 1283704 - Remove a CPOW from browser_bug812562.js to avoid a dead CPOW intermittent. r=mconley
Hey kevin, great job on this one? Want another? Feel like tackling bug 1134307?
Assignee: nobody → kevchan85
Heh, that should have been "great job on this one!", with the exclamation, and not the question mark. :)
awesome I was about to ask for a different one to work on today.
Pushed with a tweaked commit message. Thanks for fixing these, Kevin! http://mozilla-version-control-tools.readthedocs.io/en/latest/mozreview/commits.html#write-detailed-commit-messages
Pushed by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/4406e97ee4e5 Use .goBack() instead of contentWindow.history.back() to avoid CPOW usage in browser_bug812562.js. r=mconley
You need to log in before you can comment on or make changes to this bug.