BrowserUsageTelemetry.jsm: SyntaxError: Element.closest: '#widget:[addonid]@jetpack-[widgetid]' is not a valid selector
Categories
(Firefox :: Toolbars and Customization, defect, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr68 | --- | unaffected |
firefox-esr78 | --- | fixed |
firefox78 | --- | wontfix |
firefox79 | --- | fixed |
firefox80 | --- | fixed |
People
(Reporter: robwu, Assigned: mossop)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 file)
47 bytes,
text/x-phabricator-request
|
RyanVM
:
approval-mozilla-beta+
RyanVM
:
approval-mozilla-esr78+
|
Details | Review |
I opened the global JS console and see the following error:
SyntaxError: Element.closest: '#widget:[addonid]@jetpack-[widgetid]' is not a valid selector BrowserUsageTelemetry.jsm:900
_getWidgetID resource:///modules/BrowserUsageTelemetry.jsm:900
_recordCommand resource:///modules/BrowserUsageTelemetry.jsm:1032
_addUsageListeners resource:///modules/BrowserUsageTelemetry.jsm:1047
The code here in browser/modules/BrowserUsageTelemetry.jsm assumes that the input ID is a valid CSS selector. IDs do not have to be a valid CSS selector, to fix this CSS.escape
should be used first.
This ID is somehow present in my xulstore.json, and originates from a Jetpack add-on that used the sdk/widget module - https://github.com/mozilla/addon-sdk/blob/e5ce4a3c956327c25e48d49754e09bac95b0897d/lib/sdk/widget.js#L701-L702
Assignee | ||
Updated•5 years ago
|
Updated•5 years ago
|
Comment 1•5 years ago
|
||
Set release status flags based on info from the regressing bug 1620358
Updated•5 years ago
|
Updated•5 years ago
|
Assignee | ||
Comment 2•5 years ago
|
||
Assignee | ||
Comment 3•5 years ago
|
||
Updated•5 years ago
|
Comment 5•5 years ago
|
||
bugherder |
Comment 6•5 years ago
|
||
Is there a user impact which justifies backport consideration here?
Assignee | ||
Comment 7•5 years ago
|
||
(In reply to Ryan VanderMeulen [:RyanVM] from comment #6)
Is there a user impact which justifies backport consideration here?
So I don't think there is user impact. I do think it would be worth uplifting this to beta though. It breaks this interaction telemetry almost entirely for users in this state. Admittedly that number of users is probably small, but the fix is also trivial and safe.
Comment 8•5 years ago
|
||
The patch landed in nightly and beta is affected.
:mossop, is this bug important enough to require an uplift?
If not please set status_beta
to wontfix
.
For more information, please visit auto_nag documentation.
Assignee | ||
Comment 9•5 years ago
|
||
Comment on attachment 9163900 [details]
Bug 1652487: Escape widget identifiers before using them as CSS selectors. r=Gijs!
Beta/Release Uplift Approval Request
- User impact if declined: None however we lose some telemetry for those affected, that is likely a small number of folks though.
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: No
- If yes, steps to reproduce:
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): The patch just adds some additional escaping to strings, there is no risk of regression.
- String changes made/needed:
Comment 10•5 years ago
|
||
Comment on attachment 9163900 [details]
Bug 1652487: Escape widget identifiers before using them as CSS selectors. r=Gijs!
Seems like a simple-enough Telemetry fix. Approved for 79.0rc1 and 78.1esr.
Comment 11•5 years ago
|
||
bugherder uplift |
Comment 12•5 years ago
|
||
bugherder uplift |
Updated•5 years ago
|
Description
•