From 90e58a587a4906d99c6976e9004a826e19fb03b5 Mon Sep 17 00:00:00 2001 From: Sahas Subramanian Date: Tue, 6 Oct 2026 11:31:47 +0000 Subject: [PATCH] Bump component-graph to 0.6.0 The consumer and producer formulas are no longer clamped, so consumer power can be negative and producers drawing power count against the producer total. Signed-off-by: Sahas Subramanian --- RELEASE_NOTES.md | 14 +++++--------- pyproject.toml | 2 +- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 61ee6f2ad..da0f457a5 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -2,16 +2,12 @@ ## Summary - +This release updates the microgrid component graph library to v0.6.0, which stops clamping the consumer and producer formulas. Consumer power can now be negative, and a producer that draws power now makes the producer total less negative instead of counting as zero. ## Upgrading - +- The minimum supported version of [`frequenz-microgrid-component-graph`](https://github.com/frequenz-floss/frequenz-microgrid-component-graph-python) is now [v0.6.0](https://github.com/frequenz-floss/frequenz-microgrid-component-graph-python/releases/tag/v0.6.0), which stops clamping the consumer and producer formulas. This changes the values streamed by `microgrid.consumer().power` and `microgrid.producer().power`. + - Consumer power used to be clamped at zero. It can now be negative, for example when unmodeled production or a measurement mismatch is larger than the consumption. To get the old result, use `consumer.power.max(Power.zero()).build("consumer_power")`. + - Producer power used to clamp each producer at zero. A producer that draws power now adds a positive value instead of zero, so the total can be positive. For example, PV producing 10 kW and a CHP drawing 2 kW used to give -10 kW and now give -8 kW. There is one exception: when the two share a meter below the grid meter, that meter sends data, and `disable_fallback_components` is off, the meter measures them together, so they gave -8 kW before too. `producer.power.min(Power.zero()).build("producer_power")` clamps the total at zero, but it still differs from the old result when one producer draws power while another produces. + - With `ComponentGraphConfig(include_phantom_loads_in_consumer_formula=True)`, consumer power is unchanged: it still clamps each of its terms at zero. -## New Features - - - -## Bug Fixes - - diff --git a/pyproject.toml b/pyproject.toml index 747ad6409..c3433539a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -30,7 +30,7 @@ dependencies = [ # changing the version # (plugins.mkdocstrings.handlers.python.import) "frequenz-client-microgrid >= 0.18.3, < 0.19.0", - "frequenz-microgrid-component-graph >= 0.5.0, < 0.6", + "frequenz-microgrid-component-graph >= 0.6.0, < 0.7", "frequenz-client-common >= 0.3.6, < 0.5.0", "frequenz-channels >= 1.6.1, < 2.0.0", "frequenz-quantities[marshmallow] >= 1.0.0, < 2.0.0",