Closed Bug 1375490 Opened 7 years ago Closed 7 years ago

Alerts do not work correctly in OOP popup browsers

Categories

(WebExtensions :: Untriaged, defect, P1)

defect

Tracking

(firefox54 unaffected, firefox55 wontfix, firefox56 verified, firefox57 verified)

VERIFIED FIXED
mozilla57
Tracking Status
firefox54 --- unaffected
firefox55 --- wontfix
firefox56 --- verified
firefox57 --- verified

People

(Reporter: vtamas, Assigned: kmag)

References

(Blocks 1 open bug)

Details

Attachments

(5 files)

Attached image 2017-06-22_1548_001.png
[Affected versions]:
Firefox 56.0a1 (2017-06-21)
Firefox 55.0b3 (20170619141703)
 
[Affected platforms]:
Ubuntu 16.04 32-bit
Mac OS X 10.12.1
 
[Steps to reproduce]:
1.Launch Firefox with a clean profile.
2.Navigate to about:config and toggle the value of extensions.webextensions.remote to true. 
3.Restart the browser.
4.Install https://addons-dev.allizom.org/en-US/firefox/addon/tabs-tabs-tabs-oop/
5.Click on the webextension icon and select “Alert active tab info” option.
 
[Expected Results]:
The following info window is successfully displayed: https://www.screencast.com/t/37oaegROaBZc .
 

[Actual Results]:
- No info window is displayed. 
- A blank window part appears at the top of the webextension panel.
- The following error is thrown in Browser Console: 
TypeError: this.Dialog is undefined[Learn More]            tabprompts.xml:200:17
- See attached screenshot.
Summary: ”this.Dialog is undefined” error while selecting “Alert active tab info” option → Alerts do not work correctly in OOP popup browsers
Attached image 2017-07-17_1149.png
This issue also reproduces on Firefox 56.0a1 (2017-07-16) under Windows 10 64-bit. See attached screenshot.
Assignee: nobody → kmaglione+bmo
Priority: -- → P1
Comment on attachment 8892667 [details]
Bug 1375490: Part 1 - Correctly support alerts in OOP popups.

https://reviewboard.mozilla.org/r/163656/#review169064
Attachment #8892667 - Flags: review?(mixedpuppy) → review+
Comment on attachment 8892668 [details]
Bug 1375490: Part 1 - Support alerts in OOP extension sidebars.

https://reviewboard.mozilla.org/r/163658/#review169066
Attachment #8892668 - Flags: review?(mixedpuppy) → review+
Comment on attachment 8892668 [details]
Bug 1375490: Part 1 - Support alerts in OOP extension sidebars.

https://reviewboard.mozilla.org/r/163658/#review169068

Maybe fix one of the comments to be "Part 2"
Backed out for failing browser_ext_popup_corners.js on OSX and Windows:

https://hg.mozilla.org/integration/mozilla-inbound/rev/c7a34630781f45750b6a091720352cbedcd9e83f
https://hg.mozilla.org/integration/mozilla-inbound/rev/d32786c726e477e471780513f3749c1407286985
https://hg.mozilla.org/integration/mozilla-inbound/rev/6253335f2cd1adfed1c81004cbff02b8abc8ca05

Follow-up push with failures: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=ec8efb7cf1d3dc1a473c32220ed40602174d01c4&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-resultStatus=retry&filter-resultStatus=usercancel
Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=120296885&repo=mozilla-inbound

07:45:13     INFO -  318 INFO Test stand-alone browserAction popup
07:45:13     INFO -  319 INFO TEST-PASS | browser/components/extensions/test/browser/browser_ext_popup_corners.js | Expect widget not to be overflowed -
07:45:13     INFO -  Buffered messages finished
07:45:13    ERROR -  320 INFO TEST-UNEXPECTED-FAIL | browser/components/extensions/test/browser/browser_ext_popup_corners.js | Panel and view borderTopLeftRadius should be the same - Got 0px, expected 4px
07:45:13     INFO -  Stack trace:
07:45:13     INFO -  chrome://mochikit/content/browser-test.js:test_is:1002
07:45:13     INFO -  chrome://mochitests/content/browser/browser/components/extensions/test/browser/browser_ext_popup_corners.js:testPanel:60
07:45:13     INFO -  321 INFO TEST-PASS | browser/components/extensions/test/browser/browser_ext_popup_corners.js | Panel and body borderTopLeftRadius should be the same -
07:45:13     INFO -  Not taking screenshot here: see the one that was previously logged
Flags: needinfo?(kmaglione+bmo)
Comment on attachment 8892667 [details]
Bug 1375490: Part 1 - Correctly support alerts in OOP popups.

Approval Request Comment
[Feature/Bug causing the regression]: Bug 1357486
[User impact if declined]: This issue causes strange behavior when extensions try to open alert/confirm dialogs from popups.
[Is this code covered by automated tests?]: No. The relevant behavior of alert and confirm dialogs in tabs are tested. The changes should only affect alert and confirm dialogs in extension popups, which we would prefer not to support in the long term, but feel that we need to maintain at least a marginal level of support for in the short term.
[Has the fix been verified in Nightly?]: No.
[Needs manual test from QE? If yes, steps to reproduce]: STR are listed in comment 0.
[List of other uplifts needed for the feature/fix]: No.
[Is the change risky?]: No.
[Why is the change risky/not risky?]: By and large, this should only affect attempts to use alert/confirm dialogs in OOP popups, which currently cause nearly worst-case behavior.
[String changes made/needed]: None.
Flags: needinfo?(kmaglione+bmo)
Attachment #8892667 - Flags: approval-mozilla-beta?
Comment on attachment 8892668 [details]
Bug 1375490: Part 1 - Support alerts in OOP extension sidebars.

Approval Request Comment: Same as comment 12, only relating to extension sidebars rather than popups.
Attachment #8892668 - Flags: approval-mozilla-beta?
This has fixed the popup and sidebar case but not the options_ui case mentioned in duped Bug 1385548.
Flags: needinfo?(kmaglione+bmo)
(In reply to Kestrel from comment #15)
> This has fixed the popup and sidebar case but not the options_ui case
> mentioned in duped Bug 1385548.

Feel free to open another bug for that. But fixing it is not a priority for me, so you may have to find someone else to look into it if it's that important for you.
Flags: needinfo?(kmaglione+bmo)
Attached image 2017-08-04_1412.png
Verified this issue on Firefox 57.0a1 (2017-08-03) under Windows 10 64-bit, Mac OS X 10.12.3 and Ubuntu 16.04 32-bit and noticed the following:
- The alert pop-up is correctly displayed on Windows and Mac (see attached screenshot)
- The webextensions panel extends its size when alert pop-up is displayed on Ubuntu - issues tracked by Bug 1387386

Based on this testing I will mark this bug as Verified since the other issue is tracked separately.
Status: RESOLVED → VERIFIED
Comment on attachment 8892667 [details]
Bug 1375490: Part 1 - Correctly support alerts in OOP popups.

Short term fix for alerts in popup windows. Let's try this in 56 beta.
Attachment #8892667 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
This issue seems to be fixed also on Firefox 56.0b1 (20170808030909) under Windows 10 64-bit, Ubuntu 16.04 32-bit and Mac OS X 10.12.3. The alert pop-up is successfully displayed.
Comment on attachment 8892668 [details]
Bug 1375490: Part 1 - Support alerts in OOP extension sidebars.

Fixing the flag for the 2nd patch. (Looks like we correctly already landed it)
Attachment #8892668 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Product: Toolkit → WebExtensions
You need to log in before you can comment on or make changes to this bug.