Closed
Bug 1271986
Opened 9 years ago
Closed 9 years ago
Skip extended type checks in histogram_tools.py for "keyed" property as well
Categories
(Toolkit :: Telemetry, defect, P1)
Toolkit
Telemetry
Tracking
()
RESOLVED
FIXED
mozilla49
Tracking | Status | |
---|---|---|
firefox49 | --- | fixed |
People
(Reporter: gfritzsche, Assigned: gfritzsche)
References
Details
(Whiteboard: [measurement:client])
Attachments
(1 file)
Allow for Histogram.json entries with "keyed":"true" when running histogram_tools.py in the pipeline
1.43 KB,
patch
|
Dexter
:
review+
rvitillo
:
feedback+
|
Details | Diff | Splinter Review |
Similar to the properties handled by bug 1263189, but for the "keyed" property:
- Bug 1
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/mozaggregator/db.py", line 63, in <lambda>
map(lambda x: (x[0][:4], _aggregate_to_sql(x))).\
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/mozaggregator/db.py", line 120, in _aggregate_to_sql
histogram = _get_complete_histogram(channel, metric, payload["histogram"]) + [payload["sum"], payload["count"]]
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/mozaggregator/db.py", line 93, in _get_complete_histogram
histogram = Histogram(metric, {"values": values}, revision=revision).get_value(autocast=False).values
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/moztelemetry/histogram.py", line 117, in __init__
self.definition = histogram_tools.Histogram(name, histograms_definition[proper_name])
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/moztelemetry/histogram_tools.py", line 102, in __init__
self.verify_attributes(name, definition)
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/moztelemetry/histogram_tools.py", line 225, in verify_attributes
self.check_field_types(name, definition)
File "/home/hadoop/anaconda2/lib/python2.7/site-packages/moztelemetry/histogram_tools.py", line 300, in check_field_types
'should be {2}').format(key, name, type_name)
ValueError: value for key "keyed" in Histogram "ADDON_SHIM_USAGE" should be bool
Assignee | ||
Updated•9 years ago
|
Whiteboard: [measurement:client]
Assignee | ||
Comment 1•9 years ago
|
||
Attachment #8751287 -
Flags: review?(alessio.placitelli)
Attachment #8751287 -
Flags: feedback?(rvitillo)
Comment 2•9 years ago
|
||
Comment on attachment 8751287 [details] [diff] [review]
Allow for Histogram.json entries with "keyed":"true" when running histogram_tools.py in the pipeline
Review of attachment 8751287 [details] [diff] [review]:
-----------------------------------------------------------------
::: toolkit/components/telemetry/histogram_tools.py
@@ +293,5 @@
> return v
> for key in [k for k in coerce_fields if k in definition]:
> definition[key] = try_to_coerce_to_number(definition[key])
> + # This handles old "keyed":"true" definitions (bug 1271986).
> + if definition.get("keyed", None) == "true":
Do we need to care about case sensitivity here?
Assignee | ||
Comment 3•9 years ago
|
||
(In reply to Alessio Placitelli [:Dexter] from comment #2)
> Comment on attachment 8751287 [details] [diff] [review]
> Allow for Histogram.json entries with "keyed":"true" when running
> histogram_tools.py in the pipeline
>
> Review of attachment 8751287 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> ::: toolkit/components/telemetry/histogram_tools.py
> @@ +293,5 @@
> > return v
> > for key in [k for k in coerce_fields if k in definition]:
> > definition[key] = try_to_coerce_to_number(definition[key])
> > + # This handles old "keyed":"true" definitions (bug 1271986).
> > + if definition.get("keyed", None) == "true":
>
> Do we need to care about case sensitivity here?
No, this is just compatibility for the old definitions.
Comment 4•9 years ago
|
||
Comment on attachment 8751287 [details] [diff] [review]
Allow for Histogram.json entries with "keyed":"true" when running histogram_tools.py in the pipeline
Review of attachment 8751287 [details] [diff] [review]:
-----------------------------------------------------------------
This looks good to me.
Attachment #8751287 -
Flags: review?(alessio.placitelli) → review+
Updated•9 years ago
|
Attachment #8751287 -
Flags: feedback?(rvitillo) → feedback+
Assignee | ||
Updated•9 years ago
|
Keywords: checkin-needed
Keywords: checkin-needed
Comment 6•9 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
You need to log in
before you can comment on or make changes to this bug.
Description
•