flwr-nightly 1.20.0.dev20250715__py3-none-any.whl → 1.20.0.dev20250717__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- flwr/client/grpc_rere_client/connection.py +7 -7
- flwr/client/rest_client/connection.py +8 -7
- flwr/common/{inflatable_grpc_utils.py → inflatable_protobuf_utils.py} +12 -10
- flwr/common/record/array.py +2 -2
- flwr/common/serde.py +0 -28
- flwr/compat/client/app.py +14 -31
- flwr/proto/appio_pb2.py +18 -22
- flwr/proto/appio_pb2.pyi +21 -22
- flwr/proto/clientappio_pb2.py +12 -31
- flwr/proto/clientappio_pb2.pyi +0 -142
- flwr/proto/clientappio_pb2_grpc.py +128 -24
- flwr/proto/clientappio_pb2_grpc.pyi +57 -16
- flwr/server/fleet_event_log_interceptor.py +4 -0
- flwr/server/grid/grpc_grid.py +12 -9
- flwr/server/superlink/fleet/grpc_rere/server_interceptor.py +2 -5
- flwr/server/superlink/serverappio/serverappio_servicer.py +5 -9
- flwr/superexec/exec_event_log_interceptor.py +4 -0
- flwr/superexec/exec_license_interceptor.py +4 -0
- flwr/superexec/exec_user_auth_interceptor.py +4 -0
- flwr/supernode/runtime/run_clientapp.py +21 -15
- flwr/supernode/servicer/clientappio/clientappio_servicer.py +94 -25
- {flwr_nightly-1.20.0.dev20250715.dist-info → flwr_nightly-1.20.0.dev20250717.dist-info}/METADATA +1 -1
- {flwr_nightly-1.20.0.dev20250715.dist-info → flwr_nightly-1.20.0.dev20250717.dist-info}/RECORD +25 -26
- flwr/common/inflatable_rest_utils.py +0 -99
- {flwr_nightly-1.20.0.dev20250715.dist-info → flwr_nightly-1.20.0.dev20250717.dist-info}/WHEEL +0 -0
- {flwr_nightly-1.20.0.dev20250715.dist-info → flwr_nightly-1.20.0.dev20250717.dist-info}/entry_points.txt +0 -0
@@ -34,9 +34,9 @@ from flwr.common.inflatable import (
|
|
34
34
|
iterate_object_tree,
|
35
35
|
no_object_id_recompute,
|
36
36
|
)
|
37
|
-
from flwr.common.
|
38
|
-
|
39
|
-
|
37
|
+
from flwr.common.inflatable_protobuf_utils import (
|
38
|
+
make_pull_object_fn_protobuf,
|
39
|
+
make_push_object_fn_protobuf,
|
40
40
|
)
|
41
41
|
from flwr.common.inflatable_utils import (
|
42
42
|
inflate_object_from_contents,
|
@@ -277,8 +277,8 @@ def grpc_request_response( # pylint: disable=R0913,R0914,R0915,R0917
|
|
277
277
|
object_tree = response.message_object_trees[0]
|
278
278
|
all_object_contents = pull_objects(
|
279
279
|
[tree.object_id for tree in iterate_object_tree(object_tree)],
|
280
|
-
pull_object_fn=
|
281
|
-
|
280
|
+
pull_object_fn=make_pull_object_fn_protobuf(
|
281
|
+
pull_object_protobuf=stub.PullObject,
|
282
282
|
node=node,
|
283
283
|
run_id=run_id,
|
284
284
|
),
|
@@ -330,8 +330,8 @@ def grpc_request_response( # pylint: disable=R0913,R0914,R0915,R0917
|
|
330
330
|
)
|
331
331
|
push_objects(
|
332
332
|
all_objects,
|
333
|
-
push_object_fn=
|
334
|
-
|
333
|
+
push_object_fn=make_push_object_fn_protobuf(
|
334
|
+
push_object_protobuf=stub.PushObject,
|
335
335
|
node=node,
|
336
336
|
run_id=message.metadata.run_id,
|
337
337
|
),
|
@@ -14,6 +14,7 @@
|
|
14
14
|
# ==============================================================================
|
15
15
|
"""Contextmanager for a REST request-response channel to the Flower server."""
|
16
16
|
|
17
|
+
|
17
18
|
from collections.abc import Iterator
|
18
19
|
from contextlib import contextmanager
|
19
20
|
from logging import DEBUG, ERROR, INFO, WARN
|
@@ -33,9 +34,9 @@ from flwr.common.inflatable import (
|
|
33
34
|
iterate_object_tree,
|
34
35
|
no_object_id_recompute,
|
35
36
|
)
|
36
|
-
from flwr.common.
|
37
|
-
|
38
|
-
|
37
|
+
from flwr.common.inflatable_protobuf_utils import (
|
38
|
+
make_pull_object_fn_protobuf,
|
39
|
+
make_push_object_fn_protobuf,
|
39
40
|
)
|
40
41
|
from flwr.common.inflatable_utils import (
|
41
42
|
inflate_object_from_contents,
|
@@ -337,8 +338,8 @@ def http_request_response( # pylint: disable=R0913,R0914,R0915,R0917
|
|
337
338
|
object_tree = res.message_object_trees[0]
|
338
339
|
all_object_contents = pull_objects(
|
339
340
|
[tree.object_id for tree in iterate_object_tree(object_tree)],
|
340
|
-
pull_object_fn=
|
341
|
-
|
341
|
+
pull_object_fn=make_pull_object_fn_protobuf(
|
342
|
+
pull_object_protobuf=fn,
|
342
343
|
node=node,
|
343
344
|
run_id=run_id,
|
344
345
|
),
|
@@ -415,8 +416,8 @@ def http_request_response( # pylint: disable=R0913,R0914,R0915,R0917
|
|
415
416
|
try:
|
416
417
|
push_objects(
|
417
418
|
all_objects,
|
418
|
-
push_object_fn=
|
419
|
-
|
419
|
+
push_object_fn=make_push_object_fn_protobuf(
|
420
|
+
push_object_protobuf=fn,
|
420
421
|
node=node,
|
421
422
|
run_id=message_proto.metadata.run_id,
|
422
423
|
),
|
@@ -28,8 +28,8 @@ from flwr.proto.node_pb2 import Node # pylint: disable=E0611
|
|
28
28
|
from .inflatable_utils import ObjectIdNotPreregisteredError, ObjectUnavailableError
|
29
29
|
|
30
30
|
|
31
|
-
def
|
32
|
-
|
31
|
+
def make_pull_object_fn_protobuf(
|
32
|
+
pull_object_protobuf: Callable[[PullObjectRequest], PullObjectResponse],
|
33
33
|
node: Node,
|
34
34
|
run_id: int,
|
35
35
|
) -> Callable[[str], bytes]:
|
@@ -37,8 +37,9 @@ def make_pull_object_fn_grpc(
|
|
37
37
|
|
38
38
|
Parameters
|
39
39
|
----------
|
40
|
-
|
41
|
-
|
40
|
+
pull_object_protobuf : Callable[[PullObjectRequest], PullObjectResponse]
|
41
|
+
A callable that takes a `PullObjectRequest` and returns a `PullObjectResponse`.
|
42
|
+
This function is typically backed by a gRPC client stub.
|
42
43
|
node : Node
|
43
44
|
The node making the request.
|
44
45
|
run_id : int
|
@@ -54,7 +55,7 @@ def make_pull_object_fn_grpc(
|
|
54
55
|
|
55
56
|
def pull_object_fn(object_id: str) -> bytes:
|
56
57
|
request = PullObjectRequest(node=node, run_id=run_id, object_id=object_id)
|
57
|
-
response: PullObjectResponse =
|
58
|
+
response: PullObjectResponse = pull_object_protobuf(request)
|
58
59
|
if not response.object_found:
|
59
60
|
raise ObjectIdNotPreregisteredError(object_id)
|
60
61
|
if not response.object_available:
|
@@ -64,8 +65,8 @@ def make_pull_object_fn_grpc(
|
|
64
65
|
return pull_object_fn
|
65
66
|
|
66
67
|
|
67
|
-
def
|
68
|
-
|
68
|
+
def make_push_object_fn_protobuf(
|
69
|
+
push_object_protobuf: Callable[[PushObjectRequest], PushObjectResponse],
|
69
70
|
node: Node,
|
70
71
|
run_id: int,
|
71
72
|
) -> Callable[[str, bytes], None]:
|
@@ -73,8 +74,9 @@ def make_push_object_fn_grpc(
|
|
73
74
|
|
74
75
|
Parameters
|
75
76
|
----------
|
76
|
-
|
77
|
-
|
77
|
+
push_object_protobuf : Callable[[PushObjectRequest], PushObjectResponse]
|
78
|
+
A callable that takes a `PushObjectRequest` and returns a `PushObjectResponse`.
|
79
|
+
This function is typically backed by a gRPC client stub.
|
78
80
|
node : Node
|
79
81
|
The node making the request.
|
80
82
|
run_id : int
|
@@ -92,7 +94,7 @@ def make_push_object_fn_grpc(
|
|
92
94
|
request = PushObjectRequest(
|
93
95
|
node=node, run_id=run_id, object_id=object_id, object_content=object_content
|
94
96
|
)
|
95
|
-
response: PushObjectResponse =
|
97
|
+
response: PushObjectResponse = push_object_protobuf(request)
|
96
98
|
if not response.stored:
|
97
99
|
raise ObjectIdNotPreregisteredError(object_id)
|
98
100
|
|
flwr/common/record/array.py
CHANGED
@@ -321,8 +321,8 @@ class Array(InflatableObject):
|
|
321
321
|
Array
|
322
322
|
The inflated Array.
|
323
323
|
"""
|
324
|
-
if
|
325
|
-
|
324
|
+
if children is None:
|
325
|
+
children = {}
|
326
326
|
|
327
327
|
obj_body = get_object_body(object_content, cls)
|
328
328
|
|
flwr/common/serde.py
CHANGED
@@ -19,7 +19,6 @@ from collections import OrderedDict
|
|
19
19
|
from typing import Any, cast
|
20
20
|
|
21
21
|
# pylint: disable=E0611
|
22
|
-
from flwr.proto.clientappio_pb2 import ClientAppOutputCode, ClientAppOutputStatus
|
23
22
|
from flwr.proto.fab_pb2 import Fab as ProtoFab
|
24
23
|
from flwr.proto.message_pb2 import Context as ProtoContext
|
25
24
|
from flwr.proto.message_pb2 import Message as ProtoMessage
|
@@ -653,33 +652,6 @@ def run_from_proto(run_proto: ProtoRun) -> typing.Run:
|
|
653
652
|
return run
|
654
653
|
|
655
654
|
|
656
|
-
# === ClientApp status messages ===
|
657
|
-
|
658
|
-
|
659
|
-
def clientappstatus_to_proto(
|
660
|
-
status: typing.ClientAppOutputStatus,
|
661
|
-
) -> ClientAppOutputStatus:
|
662
|
-
"""Serialize `ClientAppOutputStatus` to ProtoBuf."""
|
663
|
-
code = ClientAppOutputCode.SUCCESS
|
664
|
-
if status.code == typing.ClientAppOutputCode.DEADLINE_EXCEEDED:
|
665
|
-
code = ClientAppOutputCode.DEADLINE_EXCEEDED
|
666
|
-
if status.code == typing.ClientAppOutputCode.UNKNOWN_ERROR:
|
667
|
-
code = ClientAppOutputCode.UNKNOWN_ERROR
|
668
|
-
return ClientAppOutputStatus(code=code, message=status.message)
|
669
|
-
|
670
|
-
|
671
|
-
def clientappstatus_from_proto(
|
672
|
-
msg: ClientAppOutputStatus,
|
673
|
-
) -> typing.ClientAppOutputStatus:
|
674
|
-
"""Deserialize `ClientAppOutputStatus` from ProtoBuf."""
|
675
|
-
code = typing.ClientAppOutputCode.SUCCESS
|
676
|
-
if msg.code == ClientAppOutputCode.DEADLINE_EXCEEDED:
|
677
|
-
code = typing.ClientAppOutputCode.DEADLINE_EXCEEDED
|
678
|
-
if msg.code == ClientAppOutputCode.UNKNOWN_ERROR:
|
679
|
-
code = typing.ClientAppOutputCode.UNKNOWN_ERROR
|
680
|
-
return typing.ClientAppOutputStatus(code=code, message=msg.message)
|
681
|
-
|
682
|
-
|
683
655
|
# === Run status ===
|
684
656
|
|
685
657
|
|
flwr/compat/client/app.py
CHANGED
@@ -29,8 +29,6 @@ from flwr.cli.config_utils import get_fab_metadata
|
|
29
29
|
from flwr.cli.install import install_from_fab
|
30
30
|
from flwr.client.client import Client
|
31
31
|
from flwr.client.client_app import ClientApp, LoadClientAppError
|
32
|
-
from flwr.client.grpc_adapter_client.connection import grpc_adapter
|
33
|
-
from flwr.client.grpc_rere_client.connection import grpc_request_response
|
34
32
|
from flwr.client.message_handler.message_handler import handle_control_message
|
35
33
|
from flwr.client.numpy_client import NumPyClient
|
36
34
|
from flwr.client.run_info_store import DeprecatedRunInfoStore
|
@@ -39,10 +37,7 @@ from flwr.common import GRPC_MAX_MESSAGE_LENGTH, Context, EventType, Message, ev
|
|
39
37
|
from flwr.common.address import parse_address
|
40
38
|
from flwr.common.constant import (
|
41
39
|
MAX_RETRY_DELAY,
|
42
|
-
TRANSPORT_TYPE_GRPC_ADAPTER,
|
43
40
|
TRANSPORT_TYPE_GRPC_BIDI,
|
44
|
-
TRANSPORT_TYPE_GRPC_RERE,
|
45
|
-
TRANSPORT_TYPE_REST,
|
46
41
|
TRANSPORT_TYPES,
|
47
42
|
ErrorCode,
|
48
43
|
)
|
@@ -121,10 +116,8 @@ def start_client(
|
|
121
116
|
Starts an insecure gRPC connection when True. Enables HTTPS connection
|
122
117
|
when False, using system certificates if `root_certificates` is None.
|
123
118
|
transport : Optional[str] (default: None)
|
124
|
-
|
125
|
-
|
126
|
-
- 'grpc-rere': gRPC, request-response (experimental)
|
127
|
-
- 'rest': HTTP (experimental)
|
119
|
+
**[Deprecated]** This argument is no longer supported and will be
|
120
|
+
removed in a future release.
|
128
121
|
authentication_keys : Optional[Tuple[PrivateKey, PublicKey]] (default: None)
|
129
122
|
Tuple containing the elliptic curve private key and public key for
|
130
123
|
authentication from the cryptography library.
|
@@ -180,6 +173,12 @@ def start_client(
|
|
180
173
|
)
|
181
174
|
warn_deprecated_feature(name=msg)
|
182
175
|
|
176
|
+
if transport is not None and transport != "grpc-bidi":
|
177
|
+
raise ValueError(
|
178
|
+
f"Transport type {transport} is not supported. "
|
179
|
+
"Use 'grpc-bidi' or None (default) instead."
|
180
|
+
)
|
181
|
+
|
183
182
|
event(EventType.START_CLIENT_ENTER)
|
184
183
|
start_client_internal(
|
185
184
|
server_address=server_address,
|
@@ -429,7 +428,7 @@ def start_client_internal(
|
|
429
428
|
|
430
429
|
run: Run = runs[run_id]
|
431
430
|
if get_fab is not None and run.fab_hash:
|
432
|
-
fab = get_fab(run.fab_hash, run_id)
|
431
|
+
fab = get_fab(run.fab_hash, run_id) # pylint: disable=E1102
|
433
432
|
# If `ClientApp` runs in the same process, install the FAB
|
434
433
|
install_from_fab(fab.content, flwr_path, True)
|
435
434
|
fab_id, fab_version = get_fab_metadata(fab.content)
|
@@ -573,10 +572,8 @@ def start_numpy_client(
|
|
573
572
|
Starts an insecure gRPC connection when True. Enables HTTPS connection
|
574
573
|
when False, using system certificates if `root_certificates` is None.
|
575
574
|
transport : Optional[str] (default: None)
|
576
|
-
|
577
|
-
|
578
|
-
- 'grpc-rere': gRPC, request-response (experimental)
|
579
|
-
- 'rest': HTTP (experimental)
|
575
|
+
**[Deprecated]** This argument is no longer supported and will be
|
576
|
+
removed in a future release.
|
580
577
|
|
581
578
|
Examples
|
582
579
|
--------
|
@@ -672,23 +669,9 @@ def _init_connection(transport: Optional[str], server_address: str) -> tuple[
|
|
672
669
|
if transport is None:
|
673
670
|
transport = TRANSPORT_TYPE_GRPC_BIDI
|
674
671
|
|
675
|
-
# Use
|
676
|
-
if transport ==
|
677
|
-
|
678
|
-
from requests.exceptions import ConnectionError as RequestsConnectionError
|
679
|
-
|
680
|
-
from flwr.client.rest_client.connection import http_request_response
|
681
|
-
except ModuleNotFoundError:
|
682
|
-
flwr_exit(ExitCode.COMMON_MISSING_EXTRA_REST)
|
683
|
-
if server_address[:4] != "http":
|
684
|
-
flwr_exit(ExitCode.SUPERNODE_REST_ADDRESS_INVALID)
|
685
|
-
connection, error_type = http_request_response, RequestsConnectionError
|
686
|
-
elif transport == TRANSPORT_TYPE_GRPC_RERE:
|
687
|
-
connection, error_type = grpc_request_response, RpcError
|
688
|
-
elif transport == TRANSPORT_TYPE_GRPC_ADAPTER:
|
689
|
-
connection, error_type = grpc_adapter, RpcError
|
690
|
-
elif transport == TRANSPORT_TYPE_GRPC_BIDI:
|
691
|
-
connection, error_type = grpc_connection, RpcError # type: ignore[assignment]
|
672
|
+
# Use gRPC bidirectional streaming
|
673
|
+
if transport == TRANSPORT_TYPE_GRPC_BIDI:
|
674
|
+
connection, error_type = grpc_connection, RpcError
|
692
675
|
else:
|
693
676
|
raise ValueError(
|
694
677
|
f"Unknown transport type: {transport} (possible: {TRANSPORT_TYPES})"
|
flwr/proto/appio_pb2.py
CHANGED
@@ -17,7 +17,7 @@ from flwr.proto import fab_pb2 as flwr_dot_proto_dot_fab__pb2
|
|
17
17
|
from flwr.proto import run_pb2 as flwr_dot_proto_dot_run__pb2
|
18
18
|
|
19
19
|
|
20
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x16\x66lwr/proto/appio.proto\x12\nflwr.proto\x1a\x18\x66lwr/proto/message.proto\x1a\x14\x66lwr/proto/fab.proto\x1a\x14\x66lwr/proto/run.proto\"\
|
20
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x16\x66lwr/proto/appio.proto\x12\nflwr.proto\x1a\x18\x66lwr/proto/message.proto\x1a\x14\x66lwr/proto/fab.proto\x1a\x14\x66lwr/proto/run.proto\"\x99\x01\n\x16PushAppMessagesRequest\x12\r\n\x05token\x18\x01 \x01(\t\x12*\n\rmessages_list\x18\x02 \x03(\x0b\x32\x13.flwr.proto.Message\x12\x0e\n\x06run_id\x18\x03 \x01(\x04\x12\x34\n\x14message_object_trees\x18\x04 \x03(\x0b\x32\x16.flwr.proto.ObjectTree\"\xcc\x01\n\x17PushAppMessagesResponse\x12\x13\n\x0bmessage_ids\x18\x01 \x03(\t\x12O\n\x0fobjects_to_push\x18\x02 \x03(\x0b\x32\x36.flwr.proto.PushAppMessagesResponse.ObjectsToPushEntry\x1aK\n\x12ObjectsToPushEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12$\n\x05value\x18\x02 \x01(\x0b\x32\x15.flwr.proto.ObjectIDs:\x02\x38\x01\"L\n\x16PullAppMessagesRequest\x12\r\n\x05token\x18\x01 \x01(\t\x12\x13\n\x0bmessage_ids\x18\x02 \x03(\t\x12\x0e\n\x06run_id\x18\x03 \x01(\x04\"{\n\x17PullAppMessagesResponse\x12*\n\rmessages_list\x18\x01 \x03(\x0b\x32\x13.flwr.proto.Message\x12\x34\n\x14message_object_trees\x18\x02 \x03(\x0b\x32\x16.flwr.proto.ObjectTree\"%\n\x14PullAppInputsRequest\x12\r\n\x05token\x18\x01 \x01(\t\"y\n\x15PullAppInputsResponse\x12$\n\x07\x63ontext\x18\x01 \x01(\x0b\x32\x13.flwr.proto.Context\x12\x1c\n\x03run\x18\x02 \x01(\x0b\x32\x0f.flwr.proto.Run\x12\x1c\n\x03\x66\x61\x62\x18\x03 \x01(\x0b\x32\x0f.flwr.proto.Fab\"\\\n\x15PushAppOutputsRequest\x12\r\n\x05token\x18\x01 \x01(\t\x12\x0e\n\x06run_id\x18\x02 \x01(\x04\x12$\n\x07\x63ontext\x18\x03 \x01(\x0b\x32\x13.flwr.proto.Context\"\x18\n\x16PushAppOutputsResponseb\x06proto3')
|
21
21
|
|
22
22
|
_globals = globals()
|
23
23
|
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
@@ -26,26 +26,22 @@ if _descriptor._USE_C_DESCRIPTORS == False:
|
|
26
26
|
DESCRIPTOR._options = None
|
27
27
|
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._options = None
|
28
28
|
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._serialized_options = b'8\001'
|
29
|
-
_globals['_PULLAPPMESSAGESRESPONSE_OBJECTSTOPULLENTRY']._options = None
|
30
|
-
_globals['_PULLAPPMESSAGESRESPONSE_OBJECTSTOPULLENTRY']._serialized_options = b'8\001'
|
31
29
|
_globals['_PUSHAPPMESSAGESREQUEST']._serialized_start=109
|
32
|
-
_globals['_PUSHAPPMESSAGESREQUEST']._serialized_end=
|
33
|
-
_globals['_PUSHAPPMESSAGESRESPONSE']._serialized_start=
|
34
|
-
_globals['_PUSHAPPMESSAGESRESPONSE']._serialized_end=
|
35
|
-
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._serialized_start=
|
36
|
-
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._serialized_end=
|
37
|
-
_globals['_PULLAPPMESSAGESREQUEST']._serialized_start=
|
38
|
-
_globals['_PULLAPPMESSAGESREQUEST']._serialized_end=
|
39
|
-
_globals['_PULLAPPMESSAGESRESPONSE']._serialized_start=
|
40
|
-
_globals['_PULLAPPMESSAGESRESPONSE']._serialized_end=
|
41
|
-
_globals['
|
42
|
-
_globals['
|
43
|
-
_globals['
|
44
|
-
_globals['
|
45
|
-
_globals['
|
46
|
-
_globals['
|
47
|
-
_globals['
|
48
|
-
_globals['
|
49
|
-
_globals['_PUSHAPPOUTPUTSRESPONSE']._serialized_start=975
|
50
|
-
_globals['_PUSHAPPOUTPUTSRESPONSE']._serialized_end=999
|
30
|
+
_globals['_PUSHAPPMESSAGESREQUEST']._serialized_end=262
|
31
|
+
_globals['_PUSHAPPMESSAGESRESPONSE']._serialized_start=265
|
32
|
+
_globals['_PUSHAPPMESSAGESRESPONSE']._serialized_end=469
|
33
|
+
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._serialized_start=394
|
34
|
+
_globals['_PUSHAPPMESSAGESRESPONSE_OBJECTSTOPUSHENTRY']._serialized_end=469
|
35
|
+
_globals['_PULLAPPMESSAGESREQUEST']._serialized_start=471
|
36
|
+
_globals['_PULLAPPMESSAGESREQUEST']._serialized_end=547
|
37
|
+
_globals['_PULLAPPMESSAGESRESPONSE']._serialized_start=549
|
38
|
+
_globals['_PULLAPPMESSAGESRESPONSE']._serialized_end=672
|
39
|
+
_globals['_PULLAPPINPUTSREQUEST']._serialized_start=674
|
40
|
+
_globals['_PULLAPPINPUTSREQUEST']._serialized_end=711
|
41
|
+
_globals['_PULLAPPINPUTSRESPONSE']._serialized_start=713
|
42
|
+
_globals['_PULLAPPINPUTSRESPONSE']._serialized_end=834
|
43
|
+
_globals['_PUSHAPPOUTPUTSREQUEST']._serialized_start=836
|
44
|
+
_globals['_PUSHAPPOUTPUTSREQUEST']._serialized_end=928
|
45
|
+
_globals['_PUSHAPPOUTPUTSRESPONSE']._serialized_start=930
|
46
|
+
_globals['_PUSHAPPOUTPUTSRESPONSE']._serialized_end=954
|
51
47
|
# @@protoc_insertion_point(module_scope)
|
flwr/proto/appio_pb2.pyi
CHANGED
@@ -20,9 +20,11 @@ class PushAppMessagesRequest(google.protobuf.message.Message):
|
|
20
20
|
PushAppMessages messages
|
21
21
|
"""
|
22
22
|
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
23
|
+
TOKEN_FIELD_NUMBER: builtins.int
|
23
24
|
MESSAGES_LIST_FIELD_NUMBER: builtins.int
|
24
25
|
RUN_ID_FIELD_NUMBER: builtins.int
|
25
26
|
MESSAGE_OBJECT_TREES_FIELD_NUMBER: builtins.int
|
27
|
+
token: typing.Text
|
26
28
|
@property
|
27
29
|
def messages_list(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flwr.proto.message_pb2.Message]: ...
|
28
30
|
run_id: builtins.int
|
@@ -30,11 +32,12 @@ class PushAppMessagesRequest(google.protobuf.message.Message):
|
|
30
32
|
def message_object_trees(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flwr.proto.message_pb2.ObjectTree]: ...
|
31
33
|
def __init__(self,
|
32
34
|
*,
|
35
|
+
token: typing.Text = ...,
|
33
36
|
messages_list: typing.Optional[typing.Iterable[flwr.proto.message_pb2.Message]] = ...,
|
34
37
|
run_id: builtins.int = ...,
|
35
38
|
message_object_trees: typing.Optional[typing.Iterable[flwr.proto.message_pb2.ObjectTree]] = ...,
|
36
39
|
) -> None: ...
|
37
|
-
def ClearField(self, field_name: typing_extensions.Literal["message_object_trees",b"message_object_trees","messages_list",b"messages_list","run_id",b"run_id"]) -> None: ...
|
40
|
+
def ClearField(self, field_name: typing_extensions.Literal["message_object_trees",b"message_object_trees","messages_list",b"messages_list","run_id",b"run_id","token",b"token"]) -> None: ...
|
38
41
|
global___PushAppMessagesRequest = PushAppMessagesRequest
|
39
42
|
|
40
43
|
class PushAppMessagesResponse(google.protobuf.message.Message):
|
@@ -71,55 +74,48 @@ global___PushAppMessagesResponse = PushAppMessagesResponse
|
|
71
74
|
class PullAppMessagesRequest(google.protobuf.message.Message):
|
72
75
|
"""PullAppMessages messages"""
|
73
76
|
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
77
|
+
TOKEN_FIELD_NUMBER: builtins.int
|
74
78
|
MESSAGE_IDS_FIELD_NUMBER: builtins.int
|
75
79
|
RUN_ID_FIELD_NUMBER: builtins.int
|
80
|
+
token: typing.Text
|
76
81
|
@property
|
77
82
|
def message_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[typing.Text]: ...
|
78
83
|
run_id: builtins.int
|
79
84
|
def __init__(self,
|
80
85
|
*,
|
86
|
+
token: typing.Text = ...,
|
81
87
|
message_ids: typing.Optional[typing.Iterable[typing.Text]] = ...,
|
82
88
|
run_id: builtins.int = ...,
|
83
89
|
) -> None: ...
|
84
|
-
def ClearField(self, field_name: typing_extensions.Literal["message_ids",b"message_ids","run_id",b"run_id"]) -> None: ...
|
90
|
+
def ClearField(self, field_name: typing_extensions.Literal["message_ids",b"message_ids","run_id",b"run_id","token",b"token"]) -> None: ...
|
85
91
|
global___PullAppMessagesRequest = PullAppMessagesRequest
|
86
92
|
|
87
93
|
class PullAppMessagesResponse(google.protobuf.message.Message):
|
88
94
|
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
89
|
-
class ObjectsToPullEntry(google.protobuf.message.Message):
|
90
|
-
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
91
|
-
KEY_FIELD_NUMBER: builtins.int
|
92
|
-
VALUE_FIELD_NUMBER: builtins.int
|
93
|
-
key: typing.Text
|
94
|
-
@property
|
95
|
-
def value(self) -> flwr.proto.message_pb2.ObjectIDs: ...
|
96
|
-
def __init__(self,
|
97
|
-
*,
|
98
|
-
key: typing.Text = ...,
|
99
|
-
value: typing.Optional[flwr.proto.message_pb2.ObjectIDs] = ...,
|
100
|
-
) -> None: ...
|
101
|
-
def HasField(self, field_name: typing_extensions.Literal["value",b"value"]) -> builtins.bool: ...
|
102
|
-
def ClearField(self, field_name: typing_extensions.Literal["key",b"key","value",b"value"]) -> None: ...
|
103
|
-
|
104
95
|
MESSAGES_LIST_FIELD_NUMBER: builtins.int
|
105
|
-
|
96
|
+
MESSAGE_OBJECT_TREES_FIELD_NUMBER: builtins.int
|
106
97
|
@property
|
107
98
|
def messages_list(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flwr.proto.message_pb2.Message]: ...
|
108
99
|
@property
|
109
|
-
def
|
100
|
+
def message_object_trees(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flwr.proto.message_pb2.ObjectTree]: ...
|
110
101
|
def __init__(self,
|
111
102
|
*,
|
112
103
|
messages_list: typing.Optional[typing.Iterable[flwr.proto.message_pb2.Message]] = ...,
|
113
|
-
|
104
|
+
message_object_trees: typing.Optional[typing.Iterable[flwr.proto.message_pb2.ObjectTree]] = ...,
|
114
105
|
) -> None: ...
|
115
|
-
def ClearField(self, field_name: typing_extensions.Literal["
|
106
|
+
def ClearField(self, field_name: typing_extensions.Literal["message_object_trees",b"message_object_trees","messages_list",b"messages_list"]) -> None: ...
|
116
107
|
global___PullAppMessagesResponse = PullAppMessagesResponse
|
117
108
|
|
118
109
|
class PullAppInputsRequest(google.protobuf.message.Message):
|
119
110
|
"""PullAppInputs messages"""
|
120
111
|
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
112
|
+
TOKEN_FIELD_NUMBER: builtins.int
|
113
|
+
token: typing.Text
|
121
114
|
def __init__(self,
|
115
|
+
*,
|
116
|
+
token: typing.Text = ...,
|
122
117
|
) -> None: ...
|
118
|
+
def ClearField(self, field_name: typing_extensions.Literal["token",b"token"]) -> None: ...
|
123
119
|
global___PullAppInputsRequest = PullAppInputsRequest
|
124
120
|
|
125
121
|
class PullAppInputsResponse(google.protobuf.message.Message):
|
@@ -146,18 +142,21 @@ global___PullAppInputsResponse = PullAppInputsResponse
|
|
146
142
|
class PushAppOutputsRequest(google.protobuf.message.Message):
|
147
143
|
"""PushAppInputs messages"""
|
148
144
|
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
145
|
+
TOKEN_FIELD_NUMBER: builtins.int
|
149
146
|
RUN_ID_FIELD_NUMBER: builtins.int
|
150
147
|
CONTEXT_FIELD_NUMBER: builtins.int
|
148
|
+
token: typing.Text
|
151
149
|
run_id: builtins.int
|
152
150
|
@property
|
153
151
|
def context(self) -> flwr.proto.message_pb2.Context: ...
|
154
152
|
def __init__(self,
|
155
153
|
*,
|
154
|
+
token: typing.Text = ...,
|
156
155
|
run_id: builtins.int = ...,
|
157
156
|
context: typing.Optional[flwr.proto.message_pb2.Context] = ...,
|
158
157
|
) -> None: ...
|
159
158
|
def HasField(self, field_name: typing_extensions.Literal["context",b"context"]) -> builtins.bool: ...
|
160
|
-
def ClearField(self, field_name: typing_extensions.Literal["context",b"context","run_id",b"run_id"]) -> None: ...
|
159
|
+
def ClearField(self, field_name: typing_extensions.Literal["context",b"context","run_id",b"run_id","token",b"token"]) -> None: ...
|
161
160
|
global___PushAppOutputsRequest = PushAppOutputsRequest
|
162
161
|
|
163
162
|
class PushAppOutputsResponse(google.protobuf.message.Message):
|
flwr/proto/clientappio_pb2.py
CHANGED
@@ -15,43 +15,24 @@ _sym_db = _symbol_database.Default()
|
|
15
15
|
from flwr.proto import fab_pb2 as flwr_dot_proto_dot_fab__pb2
|
16
16
|
from flwr.proto import run_pb2 as flwr_dot_proto_dot_run__pb2
|
17
17
|
from flwr.proto import message_pb2 as flwr_dot_proto_dot_message__pb2
|
18
|
+
from flwr.proto import appio_pb2 as flwr_dot_proto_dot_appio__pb2
|
18
19
|
|
19
20
|
|
20
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1c\x66lwr/proto/clientappio.proto\x12\nflwr.proto\x1a\x14\x66lwr/proto/fab.proto\x1a\x14\x66lwr/proto/run.proto\x1a\x18\x66lwr/proto/message.proto\"%\n#GetRunIdsWithPendingMessagesRequest\"7\n$GetRunIdsWithPendingMessagesResponse\x12\x0f\n\x07run_ids\x18\x01 \x03(\x04\"%\n\x13RequestTokenRequest\x12\x0e\n\x06run_id\x18\x01 \x01(\x04\"%\n\x14RequestTokenResponse\x12\r\n\x05token\x18\x01 \x01(\
|
21
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1c\x66lwr/proto/clientappio.proto\x12\nflwr.proto\x1a\x14\x66lwr/proto/fab.proto\x1a\x14\x66lwr/proto/run.proto\x1a\x18\x66lwr/proto/message.proto\x1a\x16\x66lwr/proto/appio.proto\"%\n#GetRunIdsWithPendingMessagesRequest\"7\n$GetRunIdsWithPendingMessagesResponse\x12\x0f\n\x07run_ids\x18\x01 \x03(\x04\"%\n\x13RequestTokenRequest\x12\x0e\n\x06run_id\x18\x01 \x01(\x04\"%\n\x14RequestTokenResponse\x12\r\n\x05token\x18\x01 \x01(\t2\xec\x06\n\x0b\x43lientAppIo\x12\x83\x01\n\x1cGetRunIdsWithPendingMessages\x12/.flwr.proto.GetRunIdsWithPendingMessagesRequest\x1a\x30.flwr.proto.GetRunIdsWithPendingMessagesResponse\"\x00\x12S\n\x0cRequestToken\x12\x1f.flwr.proto.RequestTokenRequest\x1a .flwr.proto.RequestTokenResponse\"\x00\x12\\\n\x13PullClientAppInputs\x12 .flwr.proto.PullAppInputsRequest\x1a!.flwr.proto.PullAppInputsResponse\"\x00\x12_\n\x14PushClientAppOutputs\x12!.flwr.proto.PushAppOutputsRequest\x1a\".flwr.proto.PushAppOutputsResponse\"\x00\x12X\n\x0bPushMessage\x12\".flwr.proto.PushAppMessagesRequest\x1a#.flwr.proto.PushAppMessagesResponse\"\x00\x12X\n\x0bPullMessage\x12\".flwr.proto.PullAppMessagesRequest\x1a#.flwr.proto.PullAppMessagesResponse\"\x00\x12M\n\nPushObject\x12\x1d.flwr.proto.PushObjectRequest\x1a\x1e.flwr.proto.PushObjectResponse\"\x00\x12M\n\nPullObject\x12\x1d.flwr.proto.PullObjectRequest\x1a\x1e.flwr.proto.PullObjectResponse\"\x00\x12q\n\x16\x43onfirmMessageReceived\x12).flwr.proto.ConfirmMessageReceivedRequest\x1a*.flwr.proto.ConfirmMessageReceivedResponse\"\x00\x62\x06proto3')
|
21
22
|
|
22
23
|
_globals = globals()
|
23
24
|
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
24
25
|
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'flwr.proto.clientappio_pb2', _globals)
|
25
26
|
if _descriptor._USE_C_DESCRIPTORS == False:
|
26
27
|
DESCRIPTOR._options = None
|
27
|
-
_globals['
|
28
|
-
_globals['
|
29
|
-
_globals['
|
30
|
-
_globals['
|
31
|
-
_globals['
|
32
|
-
_globals['
|
33
|
-
_globals['
|
34
|
-
_globals['
|
35
|
-
_globals['
|
36
|
-
_globals['
|
37
|
-
_globals['_CLIENTAPPOUTPUTSTATUS']._serialized_start=288
|
38
|
-
_globals['_CLIENTAPPOUTPUTSTATUS']._serialized_end=375
|
39
|
-
_globals['_PULLCLIENTAPPINPUTSREQUEST']._serialized_start=377
|
40
|
-
_globals['_PULLCLIENTAPPINPUTSREQUEST']._serialized_end=420
|
41
|
-
_globals['_PULLCLIENTAPPINPUTSRESPONSE']._serialized_start=422
|
42
|
-
_globals['_PULLCLIENTAPPINPUTSRESPONSE']._serialized_end=549
|
43
|
-
_globals['_PUSHCLIENTAPPOUTPUTSREQUEST']._serialized_start=551
|
44
|
-
_globals['_PUSHCLIENTAPPOUTPUTSREQUEST']._serialized_end=633
|
45
|
-
_globals['_PUSHCLIENTAPPOUTPUTSRESPONSE']._serialized_start=635
|
46
|
-
_globals['_PUSHCLIENTAPPOUTPUTSRESPONSE']._serialized_end=716
|
47
|
-
_globals['_PULLMESSAGEREQUEST']._serialized_start=718
|
48
|
-
_globals['_PULLMESSAGEREQUEST']._serialized_end=753
|
49
|
-
_globals['_PULLMESSAGERESPONSE']._serialized_start=755
|
50
|
-
_globals['_PULLMESSAGERESPONSE']._serialized_end=814
|
51
|
-
_globals['_PUSHMESSAGEREQUEST']._serialized_start=816
|
52
|
-
_globals['_PUSHMESSAGEREQUEST']._serialized_end=889
|
53
|
-
_globals['_PUSHMESSAGERESPONSE']._serialized_start=891
|
54
|
-
_globals['_PUSHMESSAGERESPONSE']._serialized_end=912
|
55
|
-
_globals['_CLIENTAPPIO']._serialized_start=993
|
56
|
-
_globals['_CLIENTAPPIO']._serialized_end=1604
|
28
|
+
_globals['_GETRUNIDSWITHPENDINGMESSAGESREQUEST']._serialized_start=138
|
29
|
+
_globals['_GETRUNIDSWITHPENDINGMESSAGESREQUEST']._serialized_end=175
|
30
|
+
_globals['_GETRUNIDSWITHPENDINGMESSAGESRESPONSE']._serialized_start=177
|
31
|
+
_globals['_GETRUNIDSWITHPENDINGMESSAGESRESPONSE']._serialized_end=232
|
32
|
+
_globals['_REQUESTTOKENREQUEST']._serialized_start=234
|
33
|
+
_globals['_REQUESTTOKENREQUEST']._serialized_end=271
|
34
|
+
_globals['_REQUESTTOKENRESPONSE']._serialized_start=273
|
35
|
+
_globals['_REQUESTTOKENRESPONSE']._serialized_end=310
|
36
|
+
_globals['_CLIENTAPPIO']._serialized_start=313
|
37
|
+
_globals['_CLIENTAPPIO']._serialized_end=1189
|
57
38
|
# @@protoc_insertion_point(module_scope)
|