Make interface for BatteryPool metrics consistent with power methods - #381
Conversation
|
47684a7 to
7df4cec
Compare
|
commits are now signed, also added a release notes entry. |
|
|
||
| * `BatteryPool` metric streaming interfaces have changed for `soc`, `capacity` and `power_bounds`: | ||
|
|
||
| ``` python |
There was a problem hiding this comment.
syntax should be ```python
And this makes me realize that we aren't testing the RELEASE_NOTES examples yet
There was a problem hiding this comment.
@leandro-lucarella-frequenz do we want to test that? If so this example would fail of course
There was a problem hiding this comment.
Mmmm, not sure about RELEASE_NOTES, sometimes we want to use old syntax/features to show an upgrade path, I would leave it outside.
There was a problem hiding this comment.
Well, that could be solved by either commenting the wold syntax/way or by having an extra ``` wrapped block that is not marked as python
There was a problem hiding this comment.
I think that adds more noise than it helps. Examples in the RELEASE NOTES are a one-off thing, if you checked the time you write them, then they don't need to be kept up to date ever again. I really think that would make writing release notes more annoying and harder to read with very little gain.
06ea0d9 to
97470e7
Compare
Signed-off-by: Sahas Subramanian <sahas.subramanian@frequenz.com>
Signed-off-by: Sahas Subramanian <sahas.subramanian@frequenz.com>
This makes their interface to be more consistent with the power and
current methods.
soc_recv = battery_pool.soc.new_receiver()
instead of:
soc_recv = battery_pool.soc()
Signed-off-by: Sahas Subramanian <sahas.subramanian@frequenz.com>
Signed-off-by: Sahas Subramanian <sahas.subramanian@proton.me>
97470e7 to
7e77a18
Compare
|
Rebased, resolved conflicts. |
The
soc,capacity,power_boundsmethods of theBatteryPoolwere directly returning receivers. They've now been converted to
properties, from which
new_receiver()has to be called, to get areceiver.
New:
Old: