Closed Bug 1664203 Opened 1 year ago Closed 1 year ago

"Send attribution request" telemetry and ping do not work after the first restart

Categories

(Firefox :: Top Sites, defect, P1)

Desktop
All
defect

Tracking

()

VERIFIED FIXED
82 Branch
Iteration:
82.2 - Sep 7 - Sep 20
Tracking Status
firefox-esr68 --- unaffected
firefox-esr78 --- unaffected
firefox80 --- unaffected
firefox81 --- verified
firefox82 --- verified

People

(Reporter: aflorinescu, Assigned: dao)

References

(Blocks 2 open bugs)

Details

Attachments

(1 file)

[Sugested Severity:]
S2

[Description:]
With "Send attribution request" set for a topsite, a ping anda telemetry event should be performed for each action.
The above works until first restart, afterwhich no ping and no telemetry is logged.

[Environment:]
Windows 10, Ubuntu 20, Mac 10.13.6
81.0b8

[Steps:]

  1. From Remote Settings administration, add a general topsite.
  2. From the Remote Settings configuration, set the above topsite to "Send attribution request to Mozilla server"
  3. Publish the changes and set Firefox to connect to the respective collection.
  4. Set a Firefox profile to connect to the configuration while switching the browser.topsites.useRemoteSetting to true.
  5. Start-up Firefox with the above profile configuration.
  6. Open a new tab and select from the address bar the topsite previously created.
  7. Open a new tab and select the previously selected topsite from the Topsites section in the about:newtab page.
  8. Restart the browser.
  9. Open a new tab and select from the address bar the topsite previously created.
  10. Open a new tab and select the previously selected topsite from the Topsites section in the about:newtab page.
[Actual Result:]

6,7. : In browser console, enabling XHR, a ping to https://topsites.mozilla.io/cid/amzn_2020_a1 (2x)
6,7,.: Opening about:telemetry#events-tab in a new tab will show:

partner_link interaction click {"partner": "google", "source": "newtab"}
partner_link interaction attribution success {"partner": "google", "source": "newtab"}
partner_link interaction click {"partner": "google", "source": "urlbar"}
partner_link interaction attribution success {"partner": "google", "source": "urlbar"}

After restart, the steps 9 and 10 do not log any ping or telemetry

[Expected Result:]

6,7,9,10. : In browser console, enabling XHR, a ping to https://topsites.mozilla.io/cid/amzn_2020_a1 (4x)
6,7,9,10.: Opening about:telemetry#events-tab in a new tab will show (2x):

partner_link interaction click {"partner": "google", "source": "newtab"}
partner_link interaction attribution success {"partner": "google", "source": "newtab"}
partner_link interaction click {"partner": "google", "source": "urlbar"}
partner_link interaction attribution success {"partner": "google", "source": "urlbar"}

So the problem here is that the google tile becomes a frecency tile after restart, for which we don't send attribution requests. This is somewhat expected when the exact URL of a frecency tile is different from the default site URL. However when the frecency tile has the exact same URL as the original default tile, I think we'd need the request. I'm not sure that we'll run into this with Amazon (i.e. whether https://www.amazon.com/?tag=partnerid&ref=foobar would end up becoming a frecency tile).

Severity: -- → S2
Priority: -- → P2
Depends on: 1664502
Iteration: --- → 82.2 - Sep 7 - Sep 20
Priority: P2 → P1
Pushed by dgottwald@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/25ad850e09ec
Send attribution request work for default tiles that became frecency tiles. r=mikedeboer
Assignee: nobody → dao+bmo
Status: NEW → ASSIGNED

Does this need to be uplifted to 81? Please nominate for release approval ASAP if so.

Flags: needinfo?(dao+bmo)
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 82 Branch

Comment on attachment 9175781 [details]
Bug 1664203 - Send attribution request for default tiles that became frecency tiles. r=mikedeboer

Beta/Release Uplift Approval Request

  • User impact if declined: See comment 0
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: See comment 0
  • List of other uplifts needed: Bug 1664502
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Straightforward fix. Top sites from remote settings are also still disabled by default -- we intend to roll out the feature after release to minimize risk.
  • String changes made/needed:
Flags: needinfo?(dao+bmo)
Attachment #9175781 - Flags: approval-mozilla-beta?
Flags: qe-verify+
Attachment #9175781 - Flags: approval-mozilla-beta? → approval-mozilla-release?
Flags: needinfo?(adrian.florinescu)

Comment on attachment 9175781 [details]
Bug 1664203 - Send attribution request for default tiles that became frecency tiles. r=mikedeboer

Approved for 81.0rc2.

Attachment #9175781 - Flags: approval-mozilla-release? → approval-mozilla-release+
QA Whiteboard: [qa-triaged]

Verified the issue as fixed with 82.0a1 2020-09-17 and 81RC2 using Mac 10.13.6 and Windows 10.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
Flags: needinfo?(adrian.florinescu)
Attachment #9175781 - Attachment description: Bug 1664203 - Send attribution request work for default tiles that became frecency tiles. r=mikedeboer → Bug 1664203 - Send attribution request for default tiles that became frecency tiles. r=mikedeboer
Depends on: 1665757

Seems that the https://www.example.com/#%YYYYMMDDHH% has a special code-path and the timestamp scenario was not covered properly as part of comment 9 scenario.
Leaving this bug verified for generic topsites and spinning bug 1665757 for timestamp type sites.

Depends on: 1665971
See Also: → 1682598
You need to log in before you can comment on or make changes to this bug.