# Frequenz Python SDK Release Notes

## Summary

This release introduces a number of breaking changes in the config manager, the new `ComponentId`/`MicrogridId` types and the `numpy` version update.  It also includes bug-fixes to the component graph and power management.

## Upgrading

* Includes a major update of the numpy dependency to v2.x.

* The logging configuration was changed, and now the logger name needs to be specified explicitly (the configuration key was used as the name before). This is to be compatible with configuration generated by the UI, which doesn't quote sub-key properly.

    - Before:

      ```toml
      [logging.loggers."frequenz.sdk.config"]
      level = "DEBUG"
      ```

    - Now:

      ```toml
      [logging.loggers.frequenz_config]
      name = "frequenz.sdk.config"
      level = "DEBUG"
      ```

* The logging configuration now uses a separate class for the root logger configuration: `RootLoggerConfig`.

    - Before:

      ```py
      LoggingConfig(root_logger=LoggerConfig(level="ERROR"))
      ```

    - Now:

      ```py
      LoggingConfig(root_logger=RootLoggerConfig(level="ERROR"))
      ```

* The SDK now depends on the `frequenz-client-microgrid` v0.7.x series. The main change is now all component and microgrid IDs need to be passed using the wrapper classes `ComponentId`/`MicrogridId` instead of `int`.

## Bug Fixes

- The power manager used to just forgot components when all proposals to them are withdrawn, leaving them at their last set power values.  This has been fixed by getting the power manager to set the components to their default powers, based on the component category (according to the table below), as the last step.


  | component category | default power                             |
  |--------------------|-------------------------------------------|
  | Battery            | 0.0                                       |
  | PV                 | Minimum power (aka max production power)  |
  | EV Chargers        | Maximum power (aka max consumption power) |

- PV Pool instances can now be created in sites without any PV.  This allows for writing generic code that works for all locations, that depends on the PV power formula, for example.

- `Success/PartialFailure` results from `PVPool.power_distribution_results` now report correct `succeeded_power` values.

- The `find_first_descendant_component` method in the component graph was allowing non-root components to be used as the root component during traversal.  This was leading to confusing behaviour when the root component couldn't be identified deterministically.  For example, if the root category was specified as a meter, it could start traversing from a different meter each time.  It is no-longer possible to specify a root category anymore and it always traverses from the `GRID` component.
