Frequenz-sdk

Latest version: v0.25.2

Safety actively analyzes 666166 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 5 of 7

0.19.0

Release Notes

Summary

Upgrading

* Remove `_soc` formula from the LogicalMeter. This feature has been moved to the BatteryPool.
* Upgrade PowerDistributingActor to handle components with the NaN metrics (247):
* if power bounds are NaN, then it tries to replace them with corresponding power bounds from adjacent component. If these components are also NaN, then it ignores battery.
* if other metrics metrics are NaN then it ignores battery.
* BatteryStatus to track that a component stopped sending messages. If the battery or its adjacent inverter stopped sending messages, then the battery would be considered as not working. (207)
* PowerDistributing to send battery status to subscribed users (205)
* Rename microgrid.Microgrid to microgrid.ConnectionManager (208)
* Change few resampler logs from info to debug, because they were polluting startup logs (238)

New Features

* A new class `SerializableRingbuffer` is now available, extending the `OrderedRingBuffer` class with the ability to load & dump the data to disk.
* Add the `run(*actors)` function for running and synchronizing the execution of actors. This new function simplifies the way actors are managed on the client side, allowing for a cleaner and more streamlined approach. Users/apps can now run actors simply by calling run(actor1, actor2, actor3...) without the need to manually call join() and deal with linting errors.
* The datasourcing actor now automatically closes all sending channels when the input channel closes.
* BatteryPool implementation for aggregating battery-inverter metrics into higher level metrics. (205)
* Add EV power and current streams to `EVChargerPool` (201)

Bug Fixes

* The resampler now correctly produces resampling windows of exact *resampling period* size, which only include samples emitted during the resampling window (see 170)

Removing

* Deprecated code (232):
* frequenz.sdk._data_ingestion
* frequenz.sdk._data_handling
* The pandas(-stubs) and pytz dependencies are no longer needed (261).


What's Changed
* Serializing Ringbuffer by mathias-baumann-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/167
* Rename microgrid.Microgrid to microgrid.ConnectionManager and its Insecure-companion by christianparpart in https://github.com/frequenz-floss/frequenz-sdk-python/pull/208
* Add EV power and current streams to `EVChargerPool` by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/201
* Change battery status when component stopped sending data by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/207
* Remove deprecated code by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/232
* Fix mypy invocation in noxfile by leandro-lucarella-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/219
* Add wrappers for the component data in unit tests by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/231
* Fix flaky LogicalMeter test_soc by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/235
* Update MockMicrogrid for use with datasourcing benchmark by mathias-baumann-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/224
* Change few resampler logs from info to debug by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/238
* Add a run() method to run/wait for actors completion by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/200
* Add & use close channel method in the registry by mathias-baumann-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/225
* Add BatteryPool implementation for aggregating battery-inverter data by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/205
* Remove `_soc` formula from the LogicalMeter by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/248
* Increase sampling rate in the flaky formula test by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/251
* Make resampling window size constant by leandro-lucarella-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/236
* Change PowerDistributor to ignore components with NaN metrics by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/247
* Update release notes by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/252
* Pin dev/test dependencies by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/256
* Fix resampler behaviour when resampling is to late by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/255
* Change BatteryPool to send metrics only when they change by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/254
* Remove pandas(-stubs) dependencies by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/261

New Contributors
* christianparpart made their first contribution in https://github.com/frequenz-floss/frequenz-sdk-python/pull/208

**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.18.0...v0.19.0

0.18.0

Release Notes

Summary

Upgrading

New Features

* A new class `OrderedRingBuffer` is now available, providing a sorted ring buffer of datetime-value pairs with tracking of any values that have not yet been written.
* Add logical meter formula for EV power.
* A `MovingWindow` class has been added that consumes a data stream from a logical meter and updates an `OrderedRingBuffer`.
* Add EVChargerPool implementation. It has only streaming state changes for ev chargers, now.
* Add 3-phase current formulas: `3-phase grid_current` and `3-phase ev_charger_current` to the LogicalMeter.


Bug Fixes

* Add COMPONENT_STATE_DISCHARGING as valid state for the inverter. DISCHARGING state was missing by mistake and this caused the power distributor to error out if the inverter is already discharging.


What's Changed
* Clean release notes by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/179
* Add 3-phase current formulas by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/164
* Sorted Ringbuffer by mathias-baumann-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/139
* Use MockMicrogridClient instead of a MockMicrogridServer in LogicalMeter tests by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/180
* Battery status with channel communication by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/171
* Update code to pass newly-released `black v23.1.0` by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/192
* Update to work with newly-release `pylint v2.16` by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/193
* Use `Sample` type with the RingBuffer by mathias-baumann-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/186
* Add logical meter formula generator for EV power by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/185
* Add an `EVChargerPool` implementation by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/194
* Add 3.11 to the supported Python versions by leandro-lucarella-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/195
* Add a Moving Window Class by matthias-wende-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/190
* Move dev dependencies to pyproject.toml by leandro-lucarella-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/199
* Add COMPONENT_STATE_DISCHARGING to valid inverter states by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/202

New Contributors
* matthias-wende-frequenz made their first contribution in https://github.com/frequenz-floss/frequenz-sdk-python/pull/190

**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.17.0...v0.18.0

0.17.0

Broken version

**This version has a major bug in the power distributor, and it is recommended not to be used. Please upgrade to v0.18.0, there are no breaking changes so updating should be trivial.**

----

Release Notes

Summary

Upgrading

* The resampler now takes a `name` argument for `add_timeseries()`. This is only used for logging purposes.

* The resampler and resampling actor now takes a `ResamplerConfig` object in the constructor instead of the individual values.

* The resampler and resampling actor can emit errors or warnings if the buffer needed to resample is too big. If it is bigger than `ResamplingConfig.max_buffer_len`, the buffer will be truncated to that length, so the resampling can lose accuracy.

* The `ResamplingFunction` now takes different arguments:

* `resampling_period_s` was removed.
* `resampler_config` is the configuration of the resampler calling the resampling function.
* `source_properties` is the properties of the source being resampled.

* Update frequenz-channel-python dependency to the latest release v0.12.0

* The `MetricFetcher` now propagates *NaN* to handle None values when `None` are not treated from the stream as `0`s. Then any `FormulaStep` can compute the results without checking for None on each value involved. However the final result is written as `None` rather than NaN/INF in the `FormulaEngine`.

New Features

* The resampler and resampling actor can now take a few new options via the new `ResamplerConfig` object:

* `warn_buffer_len`: The minimum length of the resampling buffer that will emit a warning.
* `max_buffer_len`: The maximum length of the resampling buffer.

* The resampler now infers the input sampling rate of sources and use a buffer size according to it.

This information can be consulted via `resampler.get_source_properties(source)`. The buffer size is now calculated so it can store all the needed samples requested via the combination of `resampling_period_s`, `max_data_age_in_periods` and the calculated `input_sampling_period_s`.

If we are upsampling, one sample could be enough for back-filling, but we store `max_data_age_in_periods` using `input_sampling_period_s` as period, so the resampling functions can do more complex inter/extrapolation if they need to.

If we are downsampling, we want a buffer that can hold `max_data_age_in_periods * resampling_period_s` seconds of data, and we have one sample every `input_sampling_period_s`, so we use a buffer length of: `max_data_age_in_periods * resampling_period_s / input_sampling_period_s`

Bug Fixes

* Fixed logger creationg for some modules.

Some modules didn't create the logger properly so there was no way to configure them using the standard logger configuration system. Because of this, it might have happened that some log messages were never showed, or some message that the user didn't want to get were emitted anyway.

* When automatically generating formulas for calculating grid power, include measurements from EV chargers if any are directly connected to the grid.


What's Changed
* Clear release notes by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/158
* Make resampler infer the input sampling period and buffer length by leandro-lucarella-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/136
* Handle `NaN` values in FormulaEngine by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/99
* Use stricter typing for `eval_stack` used by the FormulaEngine by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/162
* Fix minimum requirements test by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/163
* Add documentation and usage instructions for noxfile by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/166
* Move code in `util` package to `_internal` by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/168
* Add mock microgrid implementation by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/169
* Define way to create object with async constructor by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/145
* Use measurements from EV chargers when calculating grid power by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/172
* Update frequenz-channel-python to the latest release v0.12.0 by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/173
* Add missing entry to the current release notes by daniel-zullo-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/174
* Update RELEASE NOTES about logical meter bugfix by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/176
* Update release notes before release by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/178

New Contributors
* daniel-zullo-frequenz made their first contribution in https://github.com/frequenz-floss/frequenz-sdk-python/pull/99

**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.16.0...v0.17.0

0.16.4

Release Notes

Bug Fixes

- Hold on to a reference to all streaming tasks in the microgrid API client, so they don't get garbage collected.


What's Changed
* Remove broken CI steps that are not needed for v0.16.x by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/619


**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.16.3...v0.16.4

0.16.2

Release Notes

Bug Fixes

- Ping `pypantic` version to `< 2`.


What's Changed
* Limit pydantic to v1 by shsms in https://github.com/frequenz-floss/frequenz-sdk-python/pull/475


**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.16.1...v0.16.2

0.16.1

Release Notes

Bug Fixes

- Fix battery status logic: inverter that was discharging was considered as not working. So it was impossible to set any command until its state changed.

What's Changed
* Fix bug in battery status by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/237
* Update release notes by ela-kotulska-frequenz in https://github.com/frequenz-floss/frequenz-sdk-python/pull/244


**Full Changelog**: https://github.com/frequenz-floss/frequenz-sdk-python/compare/v0.16.0...v0.16.1

Page 5 of 7

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.