Closed Bug 1162619 Opened 10 years ago Closed 10 years ago

Synced Tabs disappear after refresh

Categories

(Firefox for iOS :: Home screen, defect)

Other
iOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
Tracking Status
fennec + ---

People

(Reporter: st3fan, Unassigned)

Details

(Keywords: reproducible)

Attachments

(3 files)

STR: 1) On desktop, open a few tabs, Sync 2) On iOS, log in, go to the Synced Tabs panel 3) You should see the tabs you synced 4) Open a tab 5) Tap the address bar and open the Synced Tabs panel again Expected: tabs are still there. Actual: Device shows, but no synced tabs under it.
I see this too (iPhone 6, 8.3), latest code
Keywords: reproducible
Resetting the simulator and logging in on a clean profile shows the tabs again. So that confirms that they are still on the server.
Quiting and restarting the simulator does not show the tabs. It shows the devices but no tabs. Pull to refresh makes no change. Something local state it seems. Investigating.
sqlite> select * from tabs; .. nothing .. sqlite> select * from clients; 6_vaPEKAdrhc|Stefan's TestFlight Profile|1431017553820|desktop||Darwin Pjf1r25WT7SQ|Firefox|1430926396220|mobile|phone|iOS lZhwm1A/aW9Q|Fennec (sarentz) on iPhone Simulator|1430926107890|mobile|simulator|iOS
Directly after clicking the Synced Tabs panel for the first time: sqlite> select * from tabs; 1|6_vaPEKAdrhc|http://daringfireball.net/|Daring Fireball||1430925953000 2|6_vaPEKAdrhc|https://www.mozilla.org/en-US/about/manifesto/|The Mozilla Manifesto||1430925951000 3|6_vaPEKAdrhc|http://www.apple.com/watch/|Apple - Apple Watch||1430925946000 So it seems something wipes the table after that.
updateMetadata is never called in ClientsSynchronizer. That means lastFetched is always zero. As a result, we always wipe and fetch all clients. When we wipe the clients DB, our delete cascades to tabs: "client_guid TEXT REFERENCES clients(guid) ON DELETE CASCADE", but our tabs sync respects our lastFetched, sees no change on the server, and doesn't re-fetch. The fix is to add the missing updateMetadata chain. An additional fix is to make sure we wipe (and set lastFetched to zero) in the tabs engine when we wipe clients.
Summary: Synced Tabs disappear after viewing → Synced Tabs disappear after refresh
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
tracking-fennec: ? → +
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: