Closed Bug 900953 Opened 9 years ago Closed 9 years ago

Intermittent test_bug513194.html | monitorConsole | extra message | {"message":"[JavaScript Error: \"Not a number\" {file: \"resource://gre/modules/PlacesDBUtils.jsm\" line: 975}]","errorMessage":"Not a number","sourceName":"resource://gre/modules ...

Categories

(Core :: DOM: HTML Parser, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla28
Tracking Status
firefox26 --- fixed
firefox27 --- fixed
firefox28 --- fixed
firefox-esr24 --- fixed
b2g-v1.2 --- fixed

People

(Reporter: RyanVM, Assigned: adw)

References

Details

(Keywords: intermittent-failure)

Attachments

(1 file)

https://tbpl.mozilla.org/php/getParsedLog.php?id=26067057&tree=Mozilla-Inbound

Ubuntu VM 12.04 mozilla-inbound opt test mochitest-1 on 2013-08-02 03:07:35 PDT for push 7d582e8caa96
slave: tst-linux32-ec2-011

03:12:37     INFO -  31641 INFO TEST-START | /tests/content/base/test/test_bug513194.html
03:12:37     INFO -  31642 INFO TEST-PASS | /tests/content/base/test/test_bug513194.html | monitorConsole | [0].errorMessage present
03:12:37     INFO -  31643 INFO TEST-PASS | /tests/content/base/test/test_bug513194.html | monitorConsole | [0].errorMessage value - "Unknown property 'foo'.  Declaration dropped." contains /Unknown property/
03:12:37     INFO -  31644 ERROR TEST-UNEXPECTED-FAIL | /tests/content/base/test/test_bug513194.html | monitorConsole | extra message | {"message":"[JavaScript Error: \"Not a number\" {file: \"resource://gre/modules/PlacesDBUtils.jsm\" line: 975}]","errorMessage":"Not a number","sourceName":"resource://gre/modules/PlacesDBUtils.jsm","sourceLine":"","lineNumber":975,"columnNumber":0,"category":"XPConnect JavaScript","windowID":0,"isScriptError":true,"isWarning":false,"isException":false,"isStrict":false}
03:12:38     INFO -  31645 INFO TEST-PASS | /tests/content/base/test/test_bug513194.html | monitorConsole | number of messages
03:12:38     INFO -  31646 INFO TEST-END | /tests/content/base/test/test_bug513194.html | finished in 194ms
This is the reported failing line: http://mxr.mozilla.org/mozilla-central/source/toolkit/components/places/PlacesDBUtils.jsm?rev=4654abd41ddf#975

I'm guessing that placesPageCount is 0 in this calculation, causing the "not a number" error: http://mxr.mozilla.org/mozilla-central/source/toolkit/components/places/PlacesDBUtils.jsm?rev=4654abd41ddf#929

But the numerators in any of these calculations may be NaN, too, so I don't know.

I think it's fine to let the probe callbacks return Infinity/NaN -- because what else would they return if they can't generate a value? -- so this patch checks the values before registering them with telemetry.

Or maybe we should try to figure out what's causing the NaN?
Attachment #827261 - Flags: review?(mak77)
Comment on attachment 827261 [details] [diff] [review]
sanity check probe values in PlacesDBUtils

Review of attachment 827261 [details] [diff] [review]:
-----------------------------------------------------------------

::: toolkit/components/places/PlacesDBUtils.jsm
@@ +973,5 @@
> +        if (isFinite(value)) {
> +          probeValues[aProbe.histogram] = value;
> +          Services.telemetry.getHistogramById(aProbe.histogram)
> +                            .add(value);
> +        }

I think it's ok to detect validity of the value.
Surely it would be nice to figure which probe causes that, but doesn't block fixing this.
Attachment #827261 - Flags: review?(mak77) → review+
https://hg.mozilla.org/integration/fx-team/rev/0023b94763ea
Assignee: nobody → adw
Status: NEW → ASSIGNED
https://hg.mozilla.org/mozilla-central/rev/0023b94763ea
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
You need to log in before you can comment on or make changes to this bug.