Closed Bug 1950611 Opened 20 days ago Closed 4 days ago

Closing the Firefox browser by Saving and Closing the last Tab group will show that Tab group twice after restart

Categories

(Firefox :: Tabbed Browser, defect, P2)

Desktop
Unspecified
defect
Points:
2

Tracking

()

VERIFIED FIXED
138 Branch
Tracking Status
firefox-esr128 --- disabled
firefox135 --- disabled
firefox136 --- disabled
firefox137 --- verified
firefox138 --- verified

People

(Reporter: rdoghi, Assigned: dwalker)

References

(Blocks 1 open bug)

Details

(Whiteboard: [fidefe-tabgrps-sessionstore])

Attachments

(5 files)

Attached video SaveClose2.mp4

Found in

  • 137.0a1 (2025-02-26)

Affected versions

  • 137.0a1 (2025-02-26)

Affected platforms

  • all

Steps to reproduce

  1. Have only 2 tabs open.
  2. Create a Tab group with them.
  3. Right click the Tab group and select Save and Close.
  4. Restart Firefox with the same profile.
  5. Open the list all Tabs menu.

Expected result

  • Previously saved Group is displayed once.

Actual result

  • The previously saved Group is displayed twice.

Regression range
This is a new feature for Tab groups implemented with Bug 1948078

Severity: -- → S3
Points: --- → 2
Depends on: 1948078
Priority: -- → P2
Whiteboard: [fidefe-tabgrps-sessionstore]
Assignee: nobody → dwalker
Attached video 2025-03-06_15h18_33.mp4

Please note that this issue occurs with multiple tab groups as well not just 1, After closing and reopening Firefox the list all tabs menu will show the same groups multiple times.

Attached video lastGroupDelete.mp4

Noticed a different scenario where if you have a 2nd window opened with 1 group and no free tabs, and you Delete that Tab group closing the window, it will show up in the list all tabs menu from the 1st window as Saved and Closed, but it also shows up in the Recently closed Tabs submenu where we can reopen the group and have it display twice in the List all tabs menu.

I can't seem to reproduce the initial issue on current Nightly and am struggling to reproduce it consistently from bug 1948078. This makes me think this issue is related to the concurrency problems resolved in bug 1950973, but it's hard to verify the fix when I can't repro consistently.

I am able to reproduce the issue described in comment 2.

Rares, could you confirm if you can still create duplicate saved groups now that bug 1950973 has landed?

Flags: needinfo?(rdoghi)

Yes this issue still occurs in our latest Nightly 138.0a1 (2025-03-13)

Flags: needinfo?(rdoghi)

OK, I see it now. I am able to reproduce on Windows but not MacOS. I think this is due to a difference in application behavior when closing the last window.

Attachment #9471852 - Attachment description: WIP: Bug 1950611 - avoid saving already-saved groups during deferred restore. r?dao,sthompson,jswinarton → Bug 1950611 - fix save and restore of groups when they trigger window closing. r?dao,sthompson,jswinarton

There's another related issue that I discovered on macOS. If you quit Firefox while there are no windows open, your saved groups are not persisted on the next run. This is also fixed by the attached patch.

Pushed by dwalker@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/3577fab2da6c fix save and restore of groups when they trigger window closing. r=sthompson,jswinarton,sessionstore-reviewers,tabbrowser-reviewers
Attachment #9472176 - Flags: approval-mozilla-beta?

beta Uplift Approval Request

  • User impact if declined: potential to lose saved tab groups when exiting firefox with 0 windows open (macOS)
  • Code covered by automated testing: yes
  • Fix verified in Nightly: no
  • Needs manual QE test: no
  • Steps to reproduce for manual QE testing: N/A
  • Risk associated with taking this patch: low
  • Explanation of risk level: small scope, covered by tests
  • String changes made/needed: N/A
  • Is Android affected?: no
Status: NEW → RESOLVED
Closed: 4 days ago
Resolution: --- → FIXED
Target Milestone: --- → 138 Branch
Attachment #9472176 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Verified as fixed in our latest Beta 137.0b7 ID 20250317100200 and our latest Nightly build 138.0a1 (2025-03-17)

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

Attachment

General

Created:
Updated:
Size: