[iOS] Obtain a list of "highlights" and display them in the AS panel

RESOLVED FIXED

Status

()

Firefox for iOS
General
P1
normal
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: sleroux, Assigned: sleroux)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [MobileAS])

Attachments

(1 attachment)

(Assignee)

Description

a year ago
Android equivalent: https://bugzilla.mozilla.org/show_bug.cgi?id=1293710

Part of the Activity Stream UI is surfacing 'highlights' from the user's past visits. Currently there's some work underway on Desktop to revise the way they surface this through tweaks in their SQL query and weighting algorithm.

At the moment on iOS, our Activity Stream panel displays 'Recent History'. This bug is to track work against implementing a new SQL query to pull the data needed for highlights.

Some resources:

Desktop WIP:
Scoring: https://github.com/piatra/activity-stream/blob/new-highlights-query/common/recommender/Baseline.js
Query: https://github.com/piatra/activity-stream/blob/b4b0fadbe27973a5df59278bdb0fb4a5e12cd00f/addon/PlacesProvider.js#L685
Tests: https://github.com/piatra/activity-stream/blob/new-highlights-query/content-test/common/Baseline.test.js

Android WIP:
https://reviewboard.mozilla.org/r/74968/diff/1#index_header
(Assignee)

Updated

a year ago
Priority: -- → P3
Whiteboard: [MobileAS]
(Assignee)

Updated

a year ago
Assignee: nobody → sleroux
Status: NEW → ASSIGNED
For phase 1 we can display recent history instead of highlights. This will let us ship AS faster and we can work on smarter highlights for phase 2.
No longer blocks: 1288121
(Assignee)

Updated

a year ago
Blocks: 1288121
Priority: P3 → P2
Priority: P2 → P1
(Assignee)

Comment 2

a year ago
Both Desktop [1] and Android [2] know when a bookmark was created but I can't seem to find this on iOS. The best thing I can find is the local_modified/sync_status properties that might be used to infer the creation date but doesn't seem reliable. Do we just not store this information on iOS?

[1] https://github.com/piatra/activity-stream/blob/b4b0fadbe27973a5df59278bdb0fb4a5e12cd00f/addon/PlacesProvider.js#L700
[2] https://dxr.mozilla.org/mozilla-central/source/mobile/android/base/java/org/mozilla/gecko/db/BrowserProvider.java#1177
Flags: needinfo?(rnewman)
At present we only store modified times.

Creation time isn't present in the Sync bookmark record format, so we wouldn't be able to sync it in or out. Bug 676563.

We could add it as a local column, or as a table with ON DELETE CASCADE to associate a GUID to a creation time, but of course we'd only know the creation time for bookmarks created on the local device.

Android and desktop either lie, using server-clock modified timestamps, or return NULL.
Flags: needinfo?(rnewman)
(Assignee)

Comment 4

a year ago
Created attachment 8789024 [details] [review]
Link to Github pull-request: https://github.com/mozilla/firefox-ios/pull/2084

:rnewman mind checking out my SQLite queries? I'm not the greatest at SQL and you wrote most of it in the codebase so far :)
Attachment #8789024 - Flags: review?(rnewman)
(Assignee)

Comment 5

a year ago
For easier reading of the full query: https://gist.github.com/sleroux/8653b0de73f44423b3941ff61cadbaa0
(Assignee)

Updated

a year ago
See Also: → bug 1303731
Comment on attachment 8789024 [details] [review]
Link to Github pull-request: https://github.com/mozilla/firefox-ios/pull/2084

See final comment on PR!
Attachment #8789024 - Flags: review?(rnewman) → review+
(Assignee)

Comment 7

a year ago
master https://github.com/mozilla/firefox-ios/commit/12075360c7534988f5d48a68a6482984c144c66f
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
Iteration: --- → 1.5
You need to log in before you can comment on or make changes to this bug.