Skip to content

Commit 10ca981

Browse files
committed
Fix: Make streams local, not global
Signed-off-by: Mathias L. Baumann <mathias.baumann@frequenz.com>
1 parent 0056292 commit 10ca981

1 file changed

Lines changed: 4 additions & 5 deletions

File tree

src/frequenz/client/dispatch/_client.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,6 @@
5555
class Client(BaseApiClient[dispatch_pb2_grpc.MicrogridDispatchServiceStub]):
5656
"""Dispatch API client."""
5757

58-
streams: dict[
59-
int, GrpcStreamBroadcaster[StreamMicrogridDispatchesResponse, DispatchEvent]
60-
] = {}
61-
"""A dictionary of streamers, keyed by microgrid_id."""
62-
6358
def __init__(
6459
self,
6560
*,
@@ -91,6 +86,10 @@ def __init__(
9186
),
9287
)
9388
self._metadata = (("key", key),)
89+
self.streams: dict[
90+
int, GrpcStreamBroadcaster[StreamMicrogridDispatchesResponse, DispatchEvent]
91+
] = {}
92+
"""A dictionary of streamers, keyed by microgrid_id."""
9493

9594
@property
9695
def stub(self) -> dispatch_pb2_grpc.MicrogridDispatchServiceAsyncStub:

0 commit comments

Comments
 (0)