invoking onEngagement on every provider is error prone
Categories
(Firefox :: Address Bar, task, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox128 | --- | fixed |
People
(Reporter: mak, Assigned: klubana)
References
Details
(Whiteboard: [sng][search-tech-debt])
Attachments
(1 file)
A UrlbarProvider would expect to receive onEngagement only for its own results, but currently we notify it to ALL providers.
This is very error prone as if one forgets about this detail they may end up handling the wrong results.
IIRC there was a reason related to either telemetry, impressions counting, or the experimental API (that we'd like to remove in bug 1855958 anyway), we must check.
We could then remove the various checks for result.providerName in the onEngagement implementations.
Updated•2 years ago
|
| Reporter | ||
Updated•2 years ago
|
| Reporter | ||
Comment 1•2 years ago
•
|
||
We discussed this, and we'd like to split onEngegament in: onEngagement, onAbandonment, onImpression, where onImpression won't happen for the "impression" event (we should rename it to "pause" event or such), but will rather stick to the telemetry definition (result visible when engagement or abandonment happen).
Each provider will declare which notifications it wants to handle through something like:
get notifications() {
return ["abandonment", "engagement", "impression", ...];
}
| Assignee | ||
Comment 2•2 years ago
|
||
Updated•2 years ago
|
Comment 4•1 year ago
|
||
| bugherder | ||
Description
•