Closed
Bug 1042919
Opened 10 years ago
Closed 10 years ago
Exception "TypeError: this.targetPlatforms['@@iterator'] is not a function" at XPIProvider.jsm:6069
Categories
(Toolkit :: Add-ons Manager, defect)
Toolkit
Add-ons Manager
Tracking
()
RESOLVED
FIXED
mozilla34
People
(Reporter: Irving, Assigned: Irving)
Details
Attachments
(1 file)
1.85 KB,
patch
|
mossop
:
review+
|
Details | Diff | Splinter Review |
(the line number cited is for beta 31; I think it's here: http://hg.mozilla.org/releases/mozilla-beta/annotate/1fca8495b1ce/toolkit/mozapps/extensions/internal/XPIProvider.jsm#l6073) This is the most common unhandled exception seen by telemetry reporting (in this case, for Beta/Aurora/Nightly, not analyzing Release channel yet) at https://s3-us-west-2.amazonaws.com/telemetry-public-analysis/addon_perf/data/weekly_exceptions_20140714.csv.gz It's not super-frequent; eyeballing the totals says about 18k out of 80M sessions report the error. The exception is logged from http://dxr.mozilla.org/mozilla-central/source/toolkit/mozapps/extensions/AddonManager.jsm#880, called from various places but most interestingly the blocklist service, so this could be causing blocklists to not be properly applied in some cases. {"file":"resource://gre/modules/addons/XPIProvider.jsm","message":"TypeError: this.targetPlatforms['@@iterator'] is not a function","line":6069,"context":"provider updateAddonAppDisabledStates","module":"AMI"}
Assignee | ||
Comment 1•10 years ago
|
||
Grr. for..of loops don't work to iterate [key, value] on JS Objects (only Maps).
Assignee: nobody → irving
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•10 years ago
|
||
OK, so it doesn't look like this particular bug is for..of on Object, because the field in question is supposed to be an Array and we don't even get to the line in question without successfully testing "this.targetPlatforms.length == 0" - which could mean either it's a non-empty array *or* a non-empty string. Everything I can see that assigns this makes sure it's an array, *except* the code that tries to migrate from older databases. As far as I can tell, the DB migration code (either from RDF or SQLITE) has never handled 'targetPlatforms', nor does the metadata update code, so it should be null in those cases. And, amusingly enough, the code from before the conversion from iterating the array by number to iterating by foreach (at http://hg.mozilla.org/mozilla-central/diff/254a734ccaf3/toolkit/mozapps/extensions/XPIProvider.jsm) would silently succeed if the value of AddonInternal.targetPlatforms was a string... Next step appears to be catching & adding more details to my Telemetry exception report, to see what's really going on.
Assignee | ||
Comment 3•10 years ago
|
||
Aside - should I file a bug about the lack of targetPlatforms support in metadata updates?
Attachment #8480104 -
Flags: review?(dtownsend+bugmail)
Updated•10 years ago
|
Attachment #8480104 -
Flags: review?(dtownsend+bugmail) → review+
Comment 4•10 years ago
|
||
(In reply to :Irving Reid from comment #3) > Aside - should I file a bug about the lack of targetPlatforms support in > metadata updates? Bug 404163
Assignee | ||
Comment 5•10 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/d2d24213e4aa
Comment 6•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/d2d24213e4aa
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla34
You need to log in
before you can comment on or make changes to this bug.
Description
•