Currently, the user needs to walk the component graph to check if there is a grid component meaning that the microgrid is connected to the grid.
Proposed solution
Implement the is_connected() method in Grid as a shortcut to find out if the microgrid is connected to the grid or not.
Alternatively the method can be implemented in the component graph.
What's needed?
Currently, the user needs to walk the component graph to check if there is a grid component meaning that the microgrid is connected to the grid.
Proposed solution
Implement the
is_connected()
method in Grid as a shortcut to find out if the microgrid is connected to the grid or not. Alternatively the method can be implemented in the component graph.Additional context
Originally suggested in https://github.com/frequenz-floss/frequenz-sdk-python/pull/758#discussion_r1397251645