Skip to content

Releases: frequenz-floss/frequenz-microgrid-component-graph-python

v0.5.0

Choose a tag to compare

@github-actions github-actions released this 17 Jul 13:31
Immutable release. Only release title and notes can be modified.
v0.5.0
4f22034

Frequenz Microgrid Component Graph Library Release Notes

Summary

This release updates the underlying Rust crate to v0.6.0, which brings a rewritten formula fallback engine. Generated formula strings can differ from the previous release. The default source order in per-category formulas is now component-first, and graph validation errors use a new message format. It also bumps PyO3 to 0.29 to fix a security advisory. See the Upgrading section for details.

Upgrading

  • Bumped PyO3 to 0.29 to pull in the fix for RUSTSEC out-of-bounds read advisory GHSA-36hh-v3qg-5jq4 (nth/nth_back on list/tuple iterators).

  • Updated the frequenz-microgrid-component-graph Rust crate to v0.6.0. This changes some outputs that are visible from Python:

    • The formula fallback engine was rewritten. Formulas can now contain meter-subtraction and diamond terms. Exact formula strings can differ from the previous release, even for the same graph.

    • The consumer formula now measures the non-consumer components behind one internal meter as one group: it subtracts COALESCE(#meter, component readings...) instead of each component on its own. Note: if such a meter also carries a load that is not in the component graph, that load is now subtracted together with the group while the meter reading is used.

    • Graph validation failures now raise InvalidGraphError with a message that starts with Graph validation failed:, followed by one indented line per problem. The old format was InvalidGraph: <description>. Note: some errors found while building the graph, for example a missing grid component, still use the old format. Code that matches on the message text of validation failures must be updated.

  • prefer_meters_in_component_formulas now defaults to False: per-category formulas use the component reading as the primary source and the meter as the fallback. Set it to True to restore the old meter-first order. This changes only the order of the sources; the new fallback terms from v0.6.0 are used either way.

What's Changed

  • Clear release notes by @shsms in #74
  • Add tests for steam boilers by @simonvoelcker in #71
  • Bump the compatible group with 3 updates by @dependabot[bot] in #75
  • Bump frequenz-floss/gh-action-setup-python-with-deps from 0d0d77eac3b54799f31f25a1060ef2c6ebdf9299 to e4d0b2ef8f5a1612d7827f3abaef17c931d2b946 by @dependabot[bot] in #76
  • Bump pytest-asyncio from 1.3.0 to 1.4.0 by @dependabot[bot] in #80
  • Bump pydoclint from 0.8.3 to 0.8.5 by @dependabot[bot] in #82
  • Bump mypy from 1.20.2 to 2.1.0 by @dependabot[bot] in #81
  • Bump frequenz-floss/gh-action-setup-git from 16952aac3ccc01d27412fe0dea3ea946530dcace to f9d86a01228ee1cadaac5224d4d7626f1eb23f90 by @dependabot[bot] in #77
  • Bump nox from 2025.10.16 to 2026.4.10 by @dependabot[bot] in #83
  • Bump isort from 7.0.0 to 8.0.1 by @dependabot[bot] in #84
  • Update frequenz-client-assets requirement from <0.3,>=0.1.0 to >=0.1.0,<0.4 by @dependabot[bot] in #86
  • Bump types-markdown from 3.10.2.20260408 to 3.10.2.20260518 by @dependabot[bot] in #85
  • Bump black from 26.3.1 to 26.5.1 in the minor group across 1 directory by @dependabot[bot] in #78
  • Bump frequenz-repo-config from 0.17.0 to 0.18.0 in the repo-config group across 1 directory by @dependabot[bot] in #79
  • Bump pydoclint from 0.8.5 to 0.8.6 by @dependabot[bot] in #87
  • Bump the compatible group with 3 updates by @dependabot[bot] in #88
  • Bump pyo3 from 0.27.1 to 0.29.0 in the cargo group across 1 directory by @dependabot[bot] in #89
  • Opt into FromPyObject derive for Clone pyclasses under PyO3 0.29 by @shsms in #90
  • Bump actions/checkout from 6.0.3 to 7.0.0 by @dependabot[bot] in #93
  • Bump the patch group with 2 updates by @dependabot[bot] in #94
  • Bump pydoclint from 0.8.6 to 0.9.0 by @dependabot[bot] in #96
  • Bump pytest from 9.0.3 to 9.1.1 in the minor group across 1 directory by @dependabot[bot] in #95
  • Bump the compatible group across 1 directory with 2 updates by @dependabot[bot] in #92
  • Build against component-graph v0.6.0 by @shsms in #91
  • Bump version to 0.5.0 by @shsms in #97

Full Changelog: v0.4.1...v0.5.0

v0.4.1

Choose a tag to compare

@github-actions github-actions released this 11 May 14:00
Immutable release. Only release title and notes can be modified.
v0.4.1
e97265e

Frequenz Microgrid Component Graph Library Release Notes

Upgrading

  • The microgrid extra now requires frequenz-client-microgrid >= 0.18.3 (was >= 0.18.0) so that the SteamBoiler component class is available.

New Features

  • ComponentGraph now accepts every component class shipped by frequenz.client.microgrid.component. Battery and EV-charger subtypes (LiIonBattery, NaIonBattery, AcEvCharger, DcEvCharger, HybridEvCharger) are mapped to their cg-side subtype variant instead of collapsing to Unspecified. Pass-through categories (Converter, CryptoMiner, Electrolyzer, Hvac, Precharger, Relay, VoltageTransformer), plus SteamBoiler and UnrecognizedComponent, are now mapped where they previously raised ValueError("Unsupported component category: …").

What's Changed

New Contributors

Full Changelog: v0.4.0...v0.4.1

v0.4.0

Choose a tag to compare

@github-actions github-actions released this 06 May 14:04
Immutable release. Only release title and notes can be modified.
v0.4.0
c96152e

Frequenz Microgrid Component Graph Library Release Notes

Upgrading

  • This release updates the frequenz-microgrid-component-graph rust crate version to 0.5. ComponentGraphConfig is restructured to match: the six per-category prefer_X_in_Y_formula flags are replaced by a global prefer_meters_in_component_formulas plus per-formula overrides via the new FormulaOverrides class. Also exposes the new steam_boiler_formula method, and renames battery_coalesce_formula / pv_coalesce_formula to battery_ac_coalesce_formula / pv_ac_coalesce_formula.

  • ComponentGraphConfig.__init__ is now declared as keyword-only in the type stubs (the runtime was already keyword-only, so positional calls were already failing at runtime).

  • The per-category preference flags inverted polarity: where the old flags selected the device, the new override entries select the meter. E.g. ComponentGraphConfig(prefer_inverters_in_pv_formula=True) becomes ComponentGraphConfig(formula_overrides=FormulaOverrides(prefer_meters_in_pv_formula=False)).

What's Changed

  • Add repo-config auto-migration workflow by @llucax in #46
  • Bump the patch group across 1 directory with 3 updates by @dependabot[bot] in #50
  • Bump mkdocstrings[python] from 0.30.1 to 1.0.0 by @dependabot[bot] in #30
  • Bump black from 25.9.0 to 26.3.1 by @dependabot[bot] in #52
  • Bump the compatible group across 1 directory with 3 updates by @dependabot[bot] in #48
  • Update frequenz-client-assets requirement from <0.2,>=0.1.0 to >=0.1.0,<0.3 by @dependabot[bot] in #27
  • Bump pytest-asyncio from 1.2.0 to 1.3.0 by @dependabot[bot] in #26
  • Bump actions/checkout from 5 to 6 by @dependabot[bot] in #22
  • Bump pydoclint from 0.7.6 to 0.8.3 by @dependabot[bot] in #31
  • Bump the minor group across 1 directory with 6 updates by @dependabot[bot] in #51
  • Bump mkdocstrings from 1.0.0 to 1.0.4 in the patch group across 1 directory by @dependabot[bot] in #56
  • Bump async-solipsism from 0.8 to 0.9 by @dependabot[bot] in #58
  • Bump frequenz-repo-config from 0.13.6 to 0.17.0 in the repo-config group by @dependabot[bot] in #57
  • Bump mkdocstrings-python from 1.18.2 to 2.0.3 by @dependabot[bot] in #55
  • Bump actions/create-github-app-token from 2.2.1 to 3.1.1 by @dependabot[bot] in #61
  • Bump pytest from 8.4.2 to 9.0.3 by @dependabot[bot] in #53
  • Bump the compatible group across 1 directory with 5 updates by @dependabot[bot] in #65
  • Bump mkdocs-gen-files from 0.5.0 to 0.6.1 by @dependabot[bot] in #54
  • Bump component-graph-rs version to 0.5 by @shsms in #63
  • Prepare for release 0.4 by @shsms in #67
  • Bump version to 0.4.0 by @shsms in #68
  • Update bindings version in Cargo.lock to 0.4.0 by @shsms in #69

New Contributors

Full Changelog: v0.3.4...v0.4.0

v0.3.4

Choose a tag to compare

@github-actions github-actions released this 21 Dec 15:37
Immutable release. Only release title and notes can be modified.
v0.3.4
5d224a7

Frequenz Microgrid Component Graph Library Release Notes

Upgrading

  • This release updates the frequenz-microgrid-component-graph rust crate version to 0.4.

    This introduces some behavior changes to how some formulas are calculated:

    • The PV, battery, CHP, EV and Wind Turbine formulas now prefer meters as the primary components and fallback to inverters or other corresponding components only when the meters are not available.

      This makes a big difference in performance when there are multiple PV inverters behind a single meter, for example.

      This behaviour can be changed with the newly introduced meter preference config flags.

    • Consumer formulas don't consider phantom loads by default anymore. The original behaviour is still available through a config flag.

New Features

  • This introduces a new consumer formula generator that doesn't consider phantom loads.

    Meters with successors can still have loads not represented in the component graph. These are called phantom loads.

What's Changed

Full Changelog: v0.3.3...v0.3.4

v0.3.3

Choose a tag to compare

@github-actions github-actions released this 21 Dec 15:14
Immutable release. Only release title and notes can be modified.
v0.3.3
4ab920c

Frequenz Microgrid Component Graph Library Release Notes

Upgrading

  • This release updates the frequenz-microgrid-component-graph rust crate version to 0.4.

What's Changed

  • Bump frequenz-microgrid-component-graph version to 0.4 by @shsms in #39

Full Changelog: v0.3.2...v0.3.3

v0.3.2

Choose a tag to compare

@github-actions github-actions released this 16 Dec 12:32
Immutable release. Only release title and notes can be modified.
v0.3.2
d463ca3

Frequenz Microgrid Component Graph Library Release Notes

New Features

  • It is now possible to create subclasses of the ComponentGraph and ComponentGraphConfig classes from python.

What's Changed

Full Changelog: v0.3.1...v0.3.2

v0.3.1

Choose a tag to compare

@github-actions github-actions released this 16 Dec 12:11
Immutable release. Only release title and notes can be modified.
v0.3.1
23708c7

Frequenz Microgrid Component Graph Library Release Notes

New Features

  • It is now possible to create subclasses of the ComponentGraph and ComponentGraphConfig classes from python.

What's Changed

Full Changelog: v0.3.0...v0.3.1

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 12 Dec 15:40
Immutable release. Only release title and notes can be modified.
v0.3.0
22eb3c3

Frequenz Microgrid Component Graph Library Release Notes

New Features

  • Grid formulas now use single successor meters as fallback components for meters attached to the grid.
  • Adds wind turbine bindings

What's Changed

New Contributors

Full Changelog: v0.2.0...v0.3.0

v0.2.0

Choose a tag to compare

@github-actions github-actions released this 26 Nov 16:54
Immutable release. Only release title and notes can be modified.
v0.2.0
def46db

Frequenz Microgrid Component Graph Library Release Notes

New Features

  • Grid formulas now use single successor meters as fallback components for meters attached to the grid.

What's Changed

  • CI improvements to get publishing of rust bindings to work by @shsms in #18
  • Bump version to 0.2.0 by @shsms in #19
  • Update bindings version in Cargo.lock to 0.2.0 by @shsms in #20

Full Changelog: v0.1.0...v0.2.0

v0.1.0

Choose a tag to compare

@github-actions github-actions released this 24 Nov 21:11
Immutable release. Only release title and notes can be modified.
v0.1.0
6049e83

Frequenz Microgrid Component Graph Library Release Notes

Summary

This is the initial release of the python bindings for the component graph.

Full Changelog: v0.1.0-rc4...v0.1.0