Closed Bug 1983869 Opened 7 months ago Closed 6 months ago

Clicking "extension settings" in post-install popup breaks Customize tab and keyboard shortcuts

Categories

(Toolkit :: Add-ons Manager, defect, P1)

Firefox 140
defect

Tracking

()

VERIFIED FIXED
144 Branch
Tracking Status
relnote-firefox --- 143+
firefox-esr128 --- unaffected
firefox-esr140 --- verified
firefox142 --- wontfix
firefox143 --- verified
firefox144 --- verified

People

(Reporter: hiroshi, Assigned: rpl)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [addons-jira])

Attachments

(3 files)

Changeset 5d0ea29d0b97 appends an empty fragment (#) to the current window's URL. This breaks several pieces of code that assume the window URL remains unchanged.

Steps to reproduce

  1. Install an extension (e.g. https://addons.mozilla.org/en-US/firefox/addon/firefox-color/).
  2. When the post-install popup panel appears, click the "extension settings" link.
  3. Open the Customize tab (The Application Menu [≡] > More Tools > Customize Toolbar…).

Actual results

Toolbar palette items are not appear in the Customize tab. The Browser Console shows the following error:

CustomizeMode: Error: buildWidget was called for a non-browser window!
    buildWidgetNode moz-src:///browser/components/customizableui/CustomizableUI.sys.mjs:2495
    WidgetGroupWrapper_forWindow moz-src:///browser/components/customizableui/CustomizableUI.sys.mjs:7080
    #makePaletteItem moz-src:///browser/components/customizableui/CustomizeMode.sys.mjs:1082
    #populatePalette moz-src:///browser/components/customizableui/CustomizeMode.sys.mjs:1047
    enter moz-src:///browser/components/customizableui/CustomizeMode.sys.mjs:527
CustomizeMode.sys.mjs:1069

Expected results

Toolbar palette items appear correctly in the Customize tab, and no errors are logged.

Regression changeset

https://hg-edge.mozilla.org/mozilla-central/rev/5d0ea29d0b973a91d958d08d856d56230a86fd4e

Additional symptoms and reproduction steps.

Steps to reproduce

  1. Follow Steps 1–2 from Comment 0.
  2. Press one of the following shortcut keys:
    • Ctrl+L
    • Ctrl+K
    • Alt+Home

Actual results

  • Ctrl+L: Nothing appears to happen visually. The Browser Console shows the following error:

    Uncaught InternalError: too much recursion
        openLocation chrome://browser/content/browser.js:1328
        openLocation chrome://browser/content/browser.js:1338
        ⋮
        openLocation chrome://browser/content/browser.js:1338
    browser.js:1328:7
    
  • Ctrl+K: Nothing appears to happen visually. The Browser Console shows the following error:

    Uncaught InternalError: too much recursion
        webSearch moz-src:///browser/components/search/SearchUIUtils.sys.mjs:274
        webSearch moz-src:///browser/components/search/SearchUIUtils.sys.mjs:281
        ⋮
        webSearch moz-src:///browser/components/search/SearchUIUtils.sys.mjs:281
    SearchUIUtils.sys.mjs:274:7
    
  • Alt+Home: The home page opens in a new window.

Expected results

  • Ctrl+L: Focus moves to the URL bar.
  • Ctrl+K: Focus moves to the URL bar or the search bar (if visible).
  • Alt+Home: The home page opens in the current tab.

I managed to reproduce the issue on macOS 13 using Nightly 144.0a1.

Status: UNCONFIRMED → NEW
Ever confirmed: true

:wdurand, are you able to take a look? I expect the click handler should call preventDefault or whatever.

Metadata for https://searchfox.org/firefox-main/source/browser/base/content/browser-addons.js says this goes in add-ons manager code.

bug 1866923 for an example of how these checks break things. We should fix the checks, but there are a lot of them so that may be more work than we can do quickly.

Component: Toolbars and Customization → Add-ons Manager
Flags: needinfo?(wdurand)
Keywords: regression
Product: Firefox → Toolkit
Regressed by: 1964764
See Also: → 1866923

Set release status flags based on info from the regressing bug 1964764

Assigned to myself and P1-ed it.

We should also consider uplifting to ESR.

Assignee: nobody → lgreco
Severity: -- → S4
Status: NEW → ASSIGNED
Flags: needinfo?(wdurand)
Priority: -- → P1
Whiteboard: [addons-jira]
Pushed by luca.greco@alcacoop.it: https://github.com/mozilla-firefox/firefox/commit/b9f0946c51b3 https://hg.mozilla.org/integration/autoland/rev/e335eec0da0e Fix 'extensions settings' link click handling in post-install popup to preventing it to break customize mode. r=willdurand
Status: ASSIGNED → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 144 Branch

The patch landed in nightly and beta is affected.
:rpl, is this bug important enough to require an uplift?

For more information, please visit BugBot documentation.

Flags: needinfo?(lgreco)

firefox-beta Uplift Approval Request

  • User impact if declined: After a user have clicked on the "extension settings" link part of the add-on post install dialog, the customize tab feature and some keyboard shortcuts (See Bug 1983869 comment 1) do not work anymore in the same Firefox browser window. and there may be some other features that may also break due to the assumption that the browser window url is always strictly matching the original value (as briefly mentioned in Bug 1983869 comment 3).

Only the specific Firefox browser window should be broken, while the issue should not affect other existing or newly opened Firefox browser windows.

  • Code covered by automated testing: yes
  • Fix verified in Nightly: no
  • Needs manual QE test: yes
  • Steps to reproduce for manual QE testing: STR from Bug 1983869 comment 0.
  • Risk associated with taking this patch: low
  • Explanation of risk level: The fix is small, well understood and should not have any additional side-effect. The fix is also covered explicitly by an additional assertion added to the automated tests.
  • String changes made/needed: No
  • Is Android affected?: no
Attachment #9512362 - Flags: approval-mozilla-beta?
Flags: qe-verify+

firefox-esr140 Uplift Approval Request

  • User impact if declined: - After a user have clicked on the "extension settings" link part of the add-on post install dialog, the customize tab feature and some keyboard shortcuts (See Bug 1983869 comment 1) do not work anymore in the same Firefox browser window. and there may be some other features that may also break due to the assumption that the browser window url is always strictly matching the original value (as briefly mentioned in Bug 1983869 comment 3).

Only the specific Firefox browser window should be affected, while the issue should not affect other existing or newly opened Firefox browser windows.

  • Code covered by automated testing: yes
  • Fix verified in Nightly: no
  • Needs manual QE test: yes
  • Steps to reproduce for manual QE testing: STR from Bug 1983869 comment 0.
  • Risk associated with taking this patch: low
  • Explanation of risk level: The fix is small, well understood and should not have any additional side-effect. The fix is also covered explicitly by an additional assertion added to the automated tests.
  • String changes made/needed: No
  • Is Android affected?: no
Attachment #9512375 - Flags: approval-mozilla-esr140?
Flags: needinfo?(lgreco)
QA Whiteboard: [qa-triage-done-c144/b143]

Verified as Fixed. Tested on the latest Nightly (144.0a1/20250909205747) under Windows 11 and Ubuntu 24.04 LTS using the STR from Comment 0 and Comment 1.

The toolbar palette items are displayed in the Customize tab and shortcuts work as expected.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Attachment #9512362 - Flags: approval-mozilla-beta? → approval-mozilla-release?
Attachment #9512375 - Flags: approval-mozilla-esr140? → approval-mozilla-esr140+

Verified as Fixed. Tested on the latest ESR (140.4.0esr/20250919030717 from https://treeherder.mozilla.org/jobs?repo=mozilla-esr140&revision=6054969e2149f90b801edd9179f681a7cf6039d0) under Windows 11 and Ubuntu 24.04 LTS using the STR from Comment 0 and Comment 1.

The toolbar palette items are displayed in the Customize tab and shortcuts work as expected.

Flags: in-testsuite+
Attachment #9512362 - Flags: approval-mozilla-release? → approval-mozilla-release+

Verified as Fixed. Tested on the latest Release (143.0.3/20250925195835 from https://treeherder.mozilla.org/jobs?repo=mozilla-release&revision=532de6796f942901e3943d4d241b84bcaf670ae7 as the builds there contain the fixes for this bug as well, as per the pushlog accessed via about:buildconfig) under Windows 11 and Ubuntu 24.04 LTS using the STR from Comment 0 and Comment 1.

The toolbar palette items are displayed in the Customize tab and shortcuts work as expected.

Added to the 143.0.3 relnotes.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: