Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion RELEASE_NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@

## Bug Fixes

* Fix default value of formula-aggregated metrics when no data was sent.
* Remove invalid HasField check on scalar which can cause failure retrieving formula-aggregated metrics.
2 changes: 1 addition & 1 deletion src/frequenz/client/reporting/_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ def sample(self) -> MetricSample:
metric = Metric(config.metric).name
# Ignoring this verification results in
# values of zero if the field is not set.
if sample.HasField("sample") and sample.sample.HasField("value"):
if sample.HasField("sample"):
value = sample.sample.value
else:
value = math.nan
Expand Down