Skip to content

Commit 6d068b1

Browse files
Fix consumer power formula
All grid meters have to be summed for this formula but in the current implemantation there was minus pushed to the operator stack. In this commit the sign error has been corrected. Signed-off-by: Matthias Wende <[email protected]>
1 parent d05f12d commit 6d068b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/frequenz/sdk/timeseries/_formula_engine/_formula_generators/_consumer_power_formula.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def non_consumer_component(component: Component) -> bool:
106106
# push all grid meters
107107
for idx, grid_meter in enumerate(grid_meters):
108108
if idx > 0:
109-
builder.push_oper("-")
109+
builder.push_oper("+")
110110
builder.push_component_metric(
111111
grid_meter.component_id, nones_are_zeros=False
112112
)

0 commit comments

Comments
 (0)