Closed Bug 1743709 Opened 6 months ago Closed 4 months ago

Duplicated Switch to Tab. There should not be duplications.

Categories

(Firefox :: Address Bar, defect, P3)

Firefox 96
defect
Points:
3

Tracking

()

VERIFIED FIXED
98 Branch
Tracking Status
firefox96 --- wontfix
firefox97 --- verified
firefox98 --- verified

People

(Reporter: mcheang, Assigned: mcheang)

Details

Attachments

(2 files)

Steps to reproduce

  1. Visit http://example.com.
  2. Open a new tab.
  3. Type the string example and in the drop down, place your mouse over the switch-to-tab of Example domain.
  4. Hold down the shift key to change the switch-to-tab option to url, and click it. This will open http://exmaple.com in the new tab.
  5. Close the new tab with the http://exmaple.com page.
  6. Open a new tab and click on the url bar and type the string example.
  7. In the drop down, there is now two http://example.com switch-to-tab. This is a duplication. It should only show one.

Expected:

There should only be one Example Domain Switch to Tab suggestion.

Current:

There are two Example Domain Switch to Tab suggestions. This is a duplication because on the browser, there's only one tab with example.com loaded.

Potential fix:

Investigate how to de-duplicate the switch-to-tab in the muxer.
https://searchfox.org/mozilla-central/rev/70b32246fce5ca1f53af573a21c1939df58cb969/browser/components/urlbar/UrlbarMuxerUnifiedComplete.jsm#761-767

Assignee: nobody → mcheang
Severity: -- → S3
Status: NEW → ASSIGNED
Points: --- → 3
Priority: -- → P3

Hi,
this was revised and Verified in Win10, using Nightly 97.0a1 (2022-01-05) (64-bit) and Release 95.0.2 (64-bit). Defect is no longer occuring.
In any case this needs to be revised again, please advise!.

Thanks.

Status: ASSIGNED → RESOLVED
Closed: 4 months ago
Resolution: --- → FIXED
Status: RESOLVED → VERIFIED
Pushed by mcheang@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/400d19ddbff7
Dedupe switchTab by checking if tab is already added to results. r=harry,adw
Target Milestone: --- → 98 Branch

Since the status are different for nightly and release, what's the status for beta?
For more information, please visit auto_nag documentation.

Mandy, are this bug's Version and tracking fields correct? Does it go back all the way to 96? If so, this seems like something we should uplift to 97.

Also, what happened with the bug status here... It looks like Jeronimo mistakenly resolved and verified it? The fix has not been verified by QA AFAICT.

Status: VERIFIED → RESOLVED
Closed: 4 months ago4 months ago
Flags: needinfo?(mcheang)

Comment on attachment 9257739 [details]
Bug 1743709 - Dedupe switchTab by checking if tab is already added to results. r?harry,adw

Beta/Release Uplift Approval Request

  • User impact if declined: User will see duplicated switch-to-tabs in the address bar view suggestion in certain situations where the url is in another tab and the url is also in adaptive history (the user's typed string that matches a url).
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: 1. Go to http://www.example.com/
  1. Open a new blank tab, and close the tab that has http://www.example.com/
  2. Type string example in the urlbar of the open tab and select http://www.example.com/ in the suggestion drop down
  3. Open a second new tab and type the string "example" in the urlbar
  4. There should be a duplicated switch-to-tab options for http://www.example.com/
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): This patch is not risky because it does not update critical components that would break search. The patch de-duplicates switch-to-tab in the results suggestions and does not affect any other search results that are being shown to the user.
  • String changes made/needed:
Flags: needinfo?(mcheang)
Attachment #9257739 - Flags: approval-mozilla-beta?
Flags: qe-verify+

Comment on attachment 9257739 [details]
Bug 1743709 - Dedupe switchTab by checking if tab is already added to results. r?harry,adw

Approved for 97.0b6. Thanks for including new tests for this.

Attachment #9257739 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

I've reproduced the issue using Firefox 97.0b5 and verified the fix using Beta 97.0b6 and Nightly 98.0a1 on Windows 10, MacOS 11.6 and Ubuntu 20.04.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.