diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index f80f12e..bc5a280 100644 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -6,7 +6,7 @@ ## Upgrading - +* Updates 'FilterOption' in client to be able to use reporting-api version 0.7.0 ## New Features diff --git a/pyproject.toml b/pyproject.toml index 62955da..2a2e642 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -28,11 +28,11 @@ requires-python = ">= 3.11, < 4" dependencies = [ "typing_extensions >= 4.6.1, < 5", "grpc-stubs == 1.53.0.5", - "frequenz-api-reporting >= 0.5.0, < 0.6", + "frequenz-api-reporting >= 0.7.0, < 0.8", "frequenz-client-common >= 0.3.0, < 0.4", - "grpcio >=1.66.1, < 2", - "grpcio-tools >=1.66.1, < 2", - "protobuf >=5.28.3, < 6", + "grpcio >=1.70.0, < 2", + "grpcio-tools >=1.70.0, < 2", + "protobuf >=5.29.3, < 6", "frequenz-client-base >= 0.8.0, < 0.10.0", ] dynamic = ["version"] diff --git a/src/frequenz/client/reporting/_client.py b/src/frequenz/client/reporting/_client.py index 6fc686e..97b23c3 100644 --- a/src/frequenz/client/reporting/_client.py +++ b/src/frequenz/client/reporting/_client.py @@ -18,7 +18,7 @@ from frequenz.api.reporting.v1.reporting_pb2 import ( AggregationConfig as PBAggregationConfig, ) -from frequenz.api.reporting.v1.reporting_pb2 import IncludeOptions as PBIncludeOptions +from frequenz.api.reporting.v1.reporting_pb2 import FilterOption as PBFilterOption from frequenz.api.reporting.v1.reporting_pb2 import ( MetricConnections as PBMetricConnections, ) @@ -327,16 +327,16 @@ def dt2ts(dt: datetime) -> PBTimestamp: ) incl_states = ( - PBIncludeOptions.FilterOption.FILTER_OPTION_INCLUDE + PBFilterOption.FILTER_OPTION_INCLUDE if include_states - else PBIncludeOptions.FilterOption.FILTER_OPTION_EXCLUDE + else PBFilterOption.FILTER_OPTION_EXCLUDE ) incl_bounds = ( - PBIncludeOptions.FilterOption.FILTER_OPTION_INCLUDE + PBFilterOption.FILTER_OPTION_INCLUDE if include_bounds - else PBIncludeOptions.FilterOption.FILTER_OPTION_EXCLUDE + else PBFilterOption.FILTER_OPTION_EXCLUDE ) - include_options = PBIncludeOptions( + include_options = PBReceiveMicrogridComponentsDataStreamRequest.IncludeOptions( bounds=incl_bounds, states=incl_states, )