Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(239)

Unified Diff: infra_libs/ts_mon/common/metrics.py

Issue 1531573003: Handle multiple modifications to distribution metrics correctly. (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: Add a missing test for coverage Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « infra_libs/ts_mon/common/metric_store.py ('k') | infra_libs/ts_mon/common/test/metric_store_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: infra_libs/ts_mon/common/metrics.py
diff --git a/infra_libs/ts_mon/common/metrics.py b/infra_libs/ts_mon/common/metrics.py
index 3ee301b67a7ae26b7f212dc6dbcdb782ecb7940f..0c30c0e7ad56e72358fcc949513fba36784a6292 100644
--- a/infra_libs/ts_mon/common/metrics.py
+++ b/infra_libs/ts_mon/common/metrics.py
@@ -193,7 +193,7 @@ class Metric(object):
interface.state.store.set(self.name, self._normalize_fields(fields), value,
enforce_ge=enforce_ge)
- def _incr(self, fields, delta, modify_fn=operator.add):
+ def _incr(self, fields, delta, modify_fn=None):
interface.state.store.incr(self.name, self._normalize_fields(fields), delta,
modify_fn=modify_fn)
« no previous file with comments | « infra_libs/ts_mon/common/metric_store.py ('k') | infra_libs/ts_mon/common/test/metric_store_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698