flwr-nightly 1.14.0.dev20241203__py3-none-any.whl → 1.14.0.dev20241205__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.

Potentially problematic release.


This version of flwr-nightly might be problematic. Click here for more details.

@@ -19,6 +19,11 @@ class ExecStub(object):
19
19
  request_serializer=flwr_dot_proto_dot_exec__pb2.StartRunRequest.SerializeToString,
20
20
  response_deserializer=flwr_dot_proto_dot_exec__pb2.StartRunResponse.FromString,
21
21
  )
22
+ self.StopRun = channel.unary_unary(
23
+ '/flwr.proto.Exec/StopRun',
24
+ request_serializer=flwr_dot_proto_dot_exec__pb2.StopRunRequest.SerializeToString,
25
+ response_deserializer=flwr_dot_proto_dot_exec__pb2.StopRunResponse.FromString,
26
+ )
22
27
  self.StreamLogs = channel.unary_stream(
23
28
  '/flwr.proto.Exec/StreamLogs',
24
29
  request_serializer=flwr_dot_proto_dot_exec__pb2.StreamLogsRequest.SerializeToString,
@@ -41,6 +46,13 @@ class ExecServicer(object):
41
46
  context.set_details('Method not implemented!')
42
47
  raise NotImplementedError('Method not implemented!')
43
48
 
49
+ def StopRun(self, request, context):
50
+ """Stop run upon request
51
+ """
52
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
53
+ context.set_details('Method not implemented!')
54
+ raise NotImplementedError('Method not implemented!')
55
+
44
56
  def StreamLogs(self, request, context):
45
57
  """Start log stream upon request
46
58
  """
@@ -63,6 +75,11 @@ def add_ExecServicer_to_server(servicer, server):
63
75
  request_deserializer=flwr_dot_proto_dot_exec__pb2.StartRunRequest.FromString,
64
76
  response_serializer=flwr_dot_proto_dot_exec__pb2.StartRunResponse.SerializeToString,
65
77
  ),
78
+ 'StopRun': grpc.unary_unary_rpc_method_handler(
79
+ servicer.StopRun,
80
+ request_deserializer=flwr_dot_proto_dot_exec__pb2.StopRunRequest.FromString,
81
+ response_serializer=flwr_dot_proto_dot_exec__pb2.StopRunResponse.SerializeToString,
82
+ ),
66
83
  'StreamLogs': grpc.unary_stream_rpc_method_handler(
67
84
  servicer.StreamLogs,
68
85
  request_deserializer=flwr_dot_proto_dot_exec__pb2.StreamLogsRequest.FromString,
@@ -100,6 +117,23 @@ class Exec(object):
100
117
  options, channel_credentials,
101
118
  insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
102
119
 
120
+ @staticmethod
121
+ def StopRun(request,
122
+ target,
123
+ options=(),
124
+ channel_credentials=None,
125
+ call_credentials=None,
126
+ insecure=False,
127
+ compression=None,
128
+ wait_for_ready=None,
129
+ timeout=None,
130
+ metadata=None):
131
+ return grpc.experimental.unary_unary(request, target, '/flwr.proto.Exec/StopRun',
132
+ flwr_dot_proto_dot_exec__pb2.StopRunRequest.SerializeToString,
133
+ flwr_dot_proto_dot_exec__pb2.StopRunResponse.FromString,
134
+ options, channel_credentials,
135
+ insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
136
+
103
137
  @staticmethod
104
138
  def StreamLogs(request,
105
139
  target,
@@ -14,6 +14,11 @@ class ExecStub:
14
14
  flwr.proto.exec_pb2.StartRunResponse]
15
15
  """Start run upon request"""
16
16
 
17
+ StopRun: grpc.UnaryUnaryMultiCallable[
18
+ flwr.proto.exec_pb2.StopRunRequest,
19
+ flwr.proto.exec_pb2.StopRunResponse]
20
+ """Stop run upon request"""
21
+
17
22
  StreamLogs: grpc.UnaryStreamMultiCallable[
18
23
  flwr.proto.exec_pb2.StreamLogsRequest,
19
24
  flwr.proto.exec_pb2.StreamLogsResponse]
@@ -34,6 +39,14 @@ class ExecServicer(metaclass=abc.ABCMeta):
34
39
  """Start run upon request"""
35
40
  pass
36
41
 
42
+ @abc.abstractmethod
43
+ def StopRun(self,
44
+ request: flwr.proto.exec_pb2.StopRunRequest,
45
+ context: grpc.ServicerContext,
46
+ ) -> flwr.proto.exec_pb2.StopRunResponse:
47
+ """Stop run upon request"""
48
+ pass
49
+
37
50
  @abc.abstractmethod
38
51
  def StreamLogs(self,
39
52
  request: flwr.proto.exec_pb2.StreamLogsRequest,
@@ -263,7 +263,7 @@ class ServerAppIoServicer(serverappio_pb2_grpc.ServerAppIoServicer):
263
263
  self, request: UpdateRunStatusRequest, context: grpc.ServicerContext
264
264
  ) -> UpdateRunStatusResponse:
265
265
  """Update the status of a run."""
266
- log(DEBUG, "ControlServicer.UpdateRunStatus")
266
+ log(DEBUG, "ServerAppIoServicer.UpdateRunStatus")
267
267
  state = self.state_factory.state()
268
268
 
269
269
  # Update the run status
@@ -23,19 +23,22 @@ from typing import Any
23
23
  import grpc
24
24
 
25
25
  from flwr.common import now
26
- from flwr.common.constant import LOG_STREAM_INTERVAL, Status
26
+ from flwr.common.constant import LOG_STREAM_INTERVAL, Status, SubStatus
27
27
  from flwr.common.logger import log
28
28
  from flwr.common.serde import (
29
29
  configs_record_from_proto,
30
30
  run_to_proto,
31
31
  user_config_from_proto,
32
32
  )
33
+ from flwr.common.typing import RunStatus
33
34
  from flwr.proto import exec_pb2_grpc # pylint: disable=E0611
34
35
  from flwr.proto.exec_pb2 import ( # pylint: disable=E0611
35
36
  ListRunsRequest,
36
37
  ListRunsResponse,
37
38
  StartRunRequest,
38
39
  StartRunResponse,
40
+ StopRunRequest,
41
+ StopRunResponse,
39
42
  StreamLogsRequest,
40
43
  StreamLogsResponse,
41
44
  )
@@ -126,6 +129,32 @@ class ExecServicer(exec_pb2_grpc.ExecServicer):
126
129
  # Handle `flwr ls --run-id <run_id>`
127
130
  return _create_list_runs_response({request.run_id}, state)
128
131
 
132
+ def StopRun(
133
+ self, request: StopRunRequest, context: grpc.ServicerContext
134
+ ) -> StopRunResponse:
135
+ """Stop a given run ID."""
136
+ log(INFO, "ExecServicer.StopRun")
137
+ state = self.linkstate_factory.state()
138
+
139
+ # Exit if `run_id` not found
140
+ if not state.get_run(request.run_id):
141
+ context.abort(
142
+ grpc.StatusCode.NOT_FOUND, f"Run ID {request.run_id} not found"
143
+ )
144
+
145
+ run_status = state.get_run_status({request.run_id})[request.run_id]
146
+ if run_status.status == Status.FINISHED:
147
+ context.abort(
148
+ grpc.StatusCode.FAILED_PRECONDITION,
149
+ f"Run ID {request.run_id} is already finished",
150
+ )
151
+
152
+ update_success = state.update_run_status(
153
+ run_id=request.run_id,
154
+ new_status=RunStatus(Status.FINISHED, SubStatus.STOPPED, ""),
155
+ )
156
+ return StopRunResponse(success=update_success)
157
+
129
158
 
130
159
  def _create_list_runs_response(run_ids: set[int], state: LinkState) -> ListRunsResponse:
131
160
  """Create response for `flwr ls --runs` and `flwr ls --run-id <run_id>`."""
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: flwr-nightly
3
- Version: 1.14.0.dev20241203
3
+ Version: 1.14.0.dev20241205
4
4
  Summary: Flower: A Friendly Federated AI Framework
5
5
  Home-page: https://flower.ai
6
6
  License: Apache-2.0
@@ -6,7 +6,7 @@ flwr/cli/config_utils.py,sha256=n-xNkQG_0POz5UUHyE00lthNaOjuS6IYU9Thzb_BThs,1143
6
6
  flwr/cli/example.py,sha256=1bGDYll3BXQY2kRqSN-oICqS5n1b9m0g0RvXTopXHl4,2215
7
7
  flwr/cli/install.py,sha256=kmD2dW-9B7645GAQx5es1o2W11gRHQ2Fg2E31SLomrg,8179
8
8
  flwr/cli/log.py,sha256=WlAuxZdTUYZ5bRKkm0jLWrOxHTS0TlSA5BeDtO9xF3k,6659
9
- flwr/cli/ls.py,sha256=aOQTDaRMYuh8O7Wm1CjbSvEXhwq-25QRRDbq-v5UaXY,7703
9
+ flwr/cli/ls.py,sha256=aUaP49kkg4nV2nRYfO8qgbtV_FF5xN5gCy3ziD2HbUk,11513
10
10
  flwr/cli/new/__init__.py,sha256=cQzK1WH4JP2awef1t2UQ2xjl1agVEz9rwutV18SWV1k,789
11
11
  flwr/cli/new/new.py,sha256=xgzObnhNpnGvjVs6wTj6BlJ9X-avPhRX3DuwWnk9ED0,9903
12
12
  flwr/cli/new/templates/__init__.py,sha256=4luU8RL-CK8JJCstQ_ON809W9bNTkY1l9zSaPKBkgwY,725
@@ -62,7 +62,7 @@ flwr/cli/new/templates/app/pyproject.pytorch.toml.tpl,sha256=UtH3Vslg2S8fIKIHC-d
62
62
  flwr/cli/new/templates/app/pyproject.sklearn.toml.tpl,sha256=01HArBqRrbZT3O7pXOM9MqduXMNm525wv7Sj6dvYMJE,686
63
63
  flwr/cli/new/templates/app/pyproject.tensorflow.toml.tpl,sha256=KVCIOEYNWnq6j7XOboXqZshc9aQ2PyRDUu7bZtmfJ24,710
64
64
  flwr/cli/run/__init__.py,sha256=oCd6HmQDx-sqver1gecgx-uMA38BLTSiiKpl7RGNceg,789
65
- flwr/cli/run/run.py,sha256=t4fBBc3Fq_-Ay5KA8zfkil5NVQOOJOMIN1Nto7Suwy4,6284
65
+ flwr/cli/run/run.py,sha256=5To92BOrfM5VEwNp2zzRUoz4tHE2NtazxIQICProA8k,8503
66
66
  flwr/cli/utils.py,sha256=emMUdthvoHBTB0iGQp-oFBmA5wV46lw3y3FmfXQPCsc,4500
67
67
  flwr/client/__init__.py,sha256=DGDoO0AEAfz-0CUFmLdyUUweAS64-07AOnmDfWUefK4,1192
68
68
  flwr/client/app.py,sha256=3AKrJduvki_1ATvKCQV4T9_1qZuarVVTtpnsq6_cWw0,34384
@@ -108,7 +108,7 @@ flwr/common/__init__.py,sha256=TVaoFEJE158aui1TPZQiJCDZX4RNHRyI8I55VC80HhI,3901
108
108
  flwr/common/address.py,sha256=7kM2Rqjw86-c8aKwAvrXerWqznnVv4TFJ62aSAeTn10,3017
109
109
  flwr/common/args.py,sha256=-KeQ6AZw1-G4Ifhsg4qlRnWhGH1m_OzUgxH7Z4j_0ns,6222
110
110
  flwr/common/config.py,sha256=qC1QvGAGr4faBtg3Y5dWhfyK5FggyWUMjPqg-Rx_FW4,8083
111
- flwr/common/constant.py,sha256=f8P1oB5VqqvV14ymdlOFDhPNuuy6TWtiG0CI7lFw-F8,5522
111
+ flwr/common/constant.py,sha256=G1arzDznYIlhUpkrk31-k-pJsRcOuoAoscI6bGe59nE,5792
112
112
  flwr/common/context.py,sha256=uJ-mnoC_8y_udEb3kAX-r8CPphNTWM72z1AlsvQEu54,2403
113
113
  flwr/common/date.py,sha256=NHHpESce5wYqEwoDXf09gp9U9l_5Bmlh2BsOcwS-kDM,1554
114
114
  flwr/common/differential_privacy.py,sha256=XwcJ3rWr8S8BZUocc76vLSJAXIf6OHnWkBV6-xlIRuw,6106
@@ -116,7 +116,7 @@ flwr/common/differential_privacy_constants.py,sha256=c7b7tqgvT7yMK0XN9ndiTBs4mQf
116
116
  flwr/common/dp.py,sha256=vddkvyjV2FhRoN4VuU2LeAM1UBn7dQB8_W-Qdiveal8,1978
117
117
  flwr/common/exit_handlers.py,sha256=MracJaBeoCOC7TaXK9zCJQxhrMSx9ZtczK237qvhBpU,2806
118
118
  flwr/common/grpc.py,sha256=AIPMAHsvcTlduaYKCgnoBnst1A7RZEgGqh0Ulm7qfJ0,2621
119
- flwr/common/logger.py,sha256=q_PKjfgUEH-yrjPSIvzzaKocWBqEOaILAmfKOOyEcDE,11197
119
+ flwr/common/logger.py,sha256=NQkdrtAP3NFTH_ebTTrjD2z6y-1bdoiIx9_npC-1TWw,11940
120
120
  flwr/common/message.py,sha256=4O1m0OWXBAYZz05gKgEtnoJ94J1gjo7hCNHyUXThxRo,13831
121
121
  flwr/common/object_ref.py,sha256=DavEkh-IJv_s0VeLsJvSZS5k-Ix_k1UcNXbldfNFXxM,9859
122
122
  flwr/common/parameter.py,sha256=-bFAUayToYDF50FZGrBC1hQYJCQDtB2bbr3ZuVLMtdE,2095
@@ -147,22 +147,14 @@ flwr/proto/clientappio_pb2.py,sha256=Y3PMv-JMaBGehpslgbvGY6l2u5vNpfCTFWu-fmAmBJ4
147
147
  flwr/proto/clientappio_pb2.pyi,sha256=iL6pOPmnot5wP3aXGiDfiUpp-eJIkysyju0ebPehS8Y,5670
148
148
  flwr/proto/clientappio_pb2_grpc.py,sha256=G35GhZ3iEOL8N6tu7Kn_ip4QUx4O2HveXngHAuU2YEM,6112
149
149
  flwr/proto/clientappio_pb2_grpc.pyi,sha256=cybktpMPaIMwrItd8hQaQDnRv4zNu_wgRddSqR9REyI,1822
150
- flwr/proto/common_pb2.py,sha256=uzSmq0FJdC-MriN9UGPFs7QVIFTKJmX5lyLnzcyZ5WE,2405
151
- flwr/proto/common_pb2.pyi,sha256=0ylFO7G79qqLuRg9IQUCBdgyIIFv4m8VzrfoWad4xXU,5394
152
- flwr/proto/common_pb2_grpc.py,sha256=1oboBPFxaTEXt9Aw7EAj8gXHDCNMhZD2VXqocC9l_gk,159
153
- flwr/proto/common_pb2_grpc.pyi,sha256=ff2TSiLVnG6IVQcTGzb2DIH3XRSoAvAo_RMcvbMFyc0,76
154
- flwr/proto/control_pb2.py,sha256=yaUkwY2J9uo-fdUIB5aHwVSDOuGunxaUr4ZlggifA_M,1439
155
- flwr/proto/control_pb2.pyi,sha256=XbFvpZvvrS7QcH5AFXfpRGl4hQvhd3QdKO6x0oTlCCU,165
156
- flwr/proto/control_pb2_grpc.py,sha256=FFE21nZvEILWpe1WCR5vAwgYEtpzrdG78-_SsU0gZ7w,5783
157
- flwr/proto/control_pb2_grpc.pyi,sha256=9DU4sgkzJ497a4Nq6kitZWEG4g_5MO8MevichnO0oAg,1672
158
150
  flwr/proto/error_pb2.py,sha256=LarjKL90LbwkXKlhzNrDssgl4DXcvIPve8NVCXHpsKA,1084
159
151
  flwr/proto/error_pb2.pyi,sha256=ZNH4HhJTU_KfMXlyCeg8FwU-fcUYxTqEmoJPtWtHikc,734
160
152
  flwr/proto/error_pb2_grpc.py,sha256=1oboBPFxaTEXt9Aw7EAj8gXHDCNMhZD2VXqocC9l_gk,159
161
153
  flwr/proto/error_pb2_grpc.pyi,sha256=ff2TSiLVnG6IVQcTGzb2DIH3XRSoAvAo_RMcvbMFyc0,76
162
- flwr/proto/exec_pb2.py,sha256=uKvQah9kbPj9PpduEFqpxYX0t_yWjHDMa5IBwl7vqKA,4022
163
- flwr/proto/exec_pb2.pyi,sha256=RJUqVsDKDZAxRSypeM4rhg4PCYsal_iVomps3GA_T_Y,6016
164
- flwr/proto/exec_pb2_grpc.py,sha256=kPXb_vp2Swl-1nkQEHJaqXKXi9P8pauBFemboGFgI9Q,5621
165
- flwr/proto/exec_pb2_grpc.pyi,sha256=qnefAjYPdWs-yYTPIfsbecoKWbVKjp6IFZHwN82ZGUo,1601
154
+ flwr/proto/exec_pb2.py,sha256=dSxDJm2rRXw7zhV6MTrJJyU51oqMNWDm0JUzVvD86BI,4484
155
+ flwr/proto/exec_pb2.pyi,sha256=xWfRQHFOLAxPqLkAaecihNK5_zlAfqE0NUJuSjPViXw,7145
156
+ flwr/proto/exec_pb2_grpc.py,sha256=z_9Hw-VapmkyfNlAOyvy2xJel1jo6P2oZgduOxnHPeE,7163
157
+ flwr/proto/exec_pb2_grpc.pyi,sha256=VDsnz9vJeweJdKCNyygDqSDfyR6LoHA4mwWViF2f7AI,2000
166
158
  flwr/proto/fab_pb2.py,sha256=3QSDq9pjbZoqVxsmCRDwHO5PrSjzn2vixjYxE-qPmb0,1589
167
159
  flwr/proto/fab_pb2.pyi,sha256=fXI108QaFtbl1WWTyslPbIx9c_19D0aYCoFn0xYtL4U,2277
168
160
  flwr/proto/fab_pb2_grpc.py,sha256=1oboBPFxaTEXt9Aw7EAj8gXHDCNMhZD2VXqocC9l_gk,159
@@ -261,7 +253,7 @@ flwr/server/strategy/strategy.py,sha256=cXapkD5uDrt5C-RbmWDn9FLoap3Q41i7GKvbmfbC
261
253
  flwr/server/superlink/__init__.py,sha256=8tHYCfodUlRD8PCP9fHgvu8cz5N31A2QoRVL0jDJ15E,707
262
254
  flwr/server/superlink/driver/__init__.py,sha256=5soEK5QSvxNjmJQ-CGTWROc4alSAeU0e9Ad9RDhsd3E,717
263
255
  flwr/server/superlink/driver/serverappio_grpc.py,sha256=oTogZLkfeThKdx9Q_bw6OMGHnLIryxQOHxbWi0qgaRM,2185
264
- flwr/server/superlink/driver/serverappio_servicer.py,sha256=INBSnim4wDZq-dv2RPENr3IMco1C5JqqfQAwFglHpqI,10454
256
+ flwr/server/superlink/driver/serverappio_servicer.py,sha256=nUQgQlxUfCYIvUW5NBq0ZysEL2cFoF2iQJIFabGodNE,10458
265
257
  flwr/server/superlink/ffs/__init__.py,sha256=FAY-zShcfPmOxosok2QyT6hTNMNctG8cH9s_nIl8jkI,840
266
258
  flwr/server/superlink/ffs/disk_ffs.py,sha256=yCN6CCzegnJIOaHr5nIu49wZQa4g5BByiSKshz50RKU,3296
267
259
  flwr/server/superlink/ffs/ffs.py,sha256=qLI1UfosJugu2BKOJWqHIhafTm-YiuKqGf3OGWPH0NM,2395
@@ -318,11 +310,11 @@ flwr/superexec/__init__.py,sha256=fcj366jh4RFby_vDwLroU4kepzqbnJgseZD_jUr_Mko,71
318
310
  flwr/superexec/app.py,sha256=Tt3GonnTwHrMmicwx9XaP-crP78-bf4DUWl-N5cG6zY,1841
319
311
  flwr/superexec/deployment.py,sha256=7VYmmI12zEaTHp_cQtU1GLikmqhctUHhEdshBPRFHMs,6734
320
312
  flwr/superexec/exec_grpc.py,sha256=OuhBAk7hiky9rjGceinLGIXqchtzGPQThZnwyYv6Ei0,2241
321
- flwr/superexec/exec_servicer.py,sha256=M3R3q5rg2kYz-gFN-nmiXkvjels4QbieEA0K5wks0kQ,4972
313
+ flwr/superexec/exec_servicer.py,sha256=qHWbGRuP702-JxlxFuztGlRdRoNET8G-0m1xwnoZgig,6016
322
314
  flwr/superexec/executor.py,sha256=zH3_53il6Jh0ZscIVEB9f4GNnXMeBbCGyCoBCxLgiG0,3114
323
315
  flwr/superexec/simulation.py,sha256=WQDon15oqpMopAZnwRZoTICYCfHqtkvFSqiTQ2hLD_g,4088
324
- flwr_nightly-1.14.0.dev20241203.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
325
- flwr_nightly-1.14.0.dev20241203.dist-info/METADATA,sha256=-4Da3_rV7HdZudDnBuvrnmwNjfJllk-QDwZPYna8mCc,15679
326
- flwr_nightly-1.14.0.dev20241203.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
327
- flwr_nightly-1.14.0.dev20241203.dist-info/entry_points.txt,sha256=JlNxX3qhaV18_2yj5a3kJW1ESxm31cal9iS_N_pf1Rk,538
328
- flwr_nightly-1.14.0.dev20241203.dist-info/RECORD,,
316
+ flwr_nightly-1.14.0.dev20241205.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
317
+ flwr_nightly-1.14.0.dev20241205.dist-info/METADATA,sha256=ecyc4WstQ-jGRyzojOuriJCSRC7XOs5g-3dHIM5arb8,15679
318
+ flwr_nightly-1.14.0.dev20241205.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
319
+ flwr_nightly-1.14.0.dev20241205.dist-info/entry_points.txt,sha256=JlNxX3qhaV18_2yj5a3kJW1ESxm31cal9iS_N_pf1Rk,538
320
+ flwr_nightly-1.14.0.dev20241205.dist-info/RECORD,,
flwr/proto/common_pb2.py DELETED
@@ -1,36 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # source: flwr/proto/common.proto
4
- # Protobuf Python Version: 4.25.0
5
- """Generated protocol buffer code."""
6
- from google.protobuf import descriptor as _descriptor
7
- from google.protobuf import descriptor_pool as _descriptor_pool
8
- from google.protobuf import symbol_database as _symbol_database
9
- from google.protobuf.internal import builder as _builder
10
- # @@protoc_insertion_point(imports)
11
-
12
- _sym_db = _symbol_database.Default()
13
-
14
-
15
-
16
-
17
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x17\x66lwr/proto/common.proto\x12\nflwr.proto\"\x1a\n\nDoubleList\x12\x0c\n\x04vals\x18\x01 \x03(\x01\"\x1a\n\nSint64List\x12\x0c\n\x04vals\x18\x01 \x03(\x12\"\x18\n\x08\x42oolList\x12\x0c\n\x04vals\x18\x01 \x03(\x08\"\x1a\n\nStringList\x12\x0c\n\x04vals\x18\x01 \x03(\t\"\x19\n\tBytesList\x12\x0c\n\x04vals\x18\x01 \x03(\x0c\"\xd9\x02\n\x12\x43onfigsRecordValue\x12\x10\n\x06\x64ouble\x18\x01 \x01(\x01H\x00\x12\x10\n\x06sint64\x18\x02 \x01(\x12H\x00\x12\x0e\n\x04\x62ool\x18\x03 \x01(\x08H\x00\x12\x10\n\x06string\x18\x04 \x01(\tH\x00\x12\x0f\n\x05\x62ytes\x18\x05 \x01(\x0cH\x00\x12-\n\x0b\x64ouble_list\x18\x15 \x01(\x0b\x32\x16.flwr.proto.DoubleListH\x00\x12-\n\x0bsint64_list\x18\x16 \x01(\x0b\x32\x16.flwr.proto.Sint64ListH\x00\x12)\n\tbool_list\x18\x17 \x01(\x0b\x32\x14.flwr.proto.BoolListH\x00\x12-\n\x0bstring_list\x18\x18 \x01(\x0b\x32\x16.flwr.proto.StringListH\x00\x12+\n\nbytes_list\x18\x19 \x01(\x0b\x32\x15.flwr.proto.BytesListH\x00\x42\x07\n\x05valueb\x06proto3')
18
-
19
- _globals = globals()
20
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
21
- _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'flwr.proto.common_pb2', _globals)
22
- if _descriptor._USE_C_DESCRIPTORS == False:
23
- DESCRIPTOR._options = None
24
- _globals['_DOUBLELIST']._serialized_start=39
25
- _globals['_DOUBLELIST']._serialized_end=65
26
- _globals['_SINT64LIST']._serialized_start=67
27
- _globals['_SINT64LIST']._serialized_end=93
28
- _globals['_BOOLLIST']._serialized_start=95
29
- _globals['_BOOLLIST']._serialized_end=119
30
- _globals['_STRINGLIST']._serialized_start=121
31
- _globals['_STRINGLIST']._serialized_end=147
32
- _globals['_BYTESLIST']._serialized_start=149
33
- _globals['_BYTESLIST']._serialized_end=174
34
- _globals['_CONFIGSRECORDVALUE']._serialized_start=177
35
- _globals['_CONFIGSRECORDVALUE']._serialized_end=522
36
- # @@protoc_insertion_point(module_scope)
flwr/proto/common_pb2.pyi DELETED
@@ -1,121 +0,0 @@
1
- """
2
- @generated by mypy-protobuf. Do not edit manually!
3
- isort:skip_file
4
- """
5
- import builtins
6
- import google.protobuf.descriptor
7
- import google.protobuf.internal.containers
8
- import google.protobuf.message
9
- import typing
10
- import typing_extensions
11
-
12
- DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
13
-
14
- class DoubleList(google.protobuf.message.Message):
15
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
16
- VALS_FIELD_NUMBER: builtins.int
17
- @property
18
- def vals(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.float]: ...
19
- def __init__(self,
20
- *,
21
- vals: typing.Optional[typing.Iterable[builtins.float]] = ...,
22
- ) -> None: ...
23
- def ClearField(self, field_name: typing_extensions.Literal["vals",b"vals"]) -> None: ...
24
- global___DoubleList = DoubleList
25
-
26
- class Sint64List(google.protobuf.message.Message):
27
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
28
- VALS_FIELD_NUMBER: builtins.int
29
- @property
30
- def vals(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.int]: ...
31
- def __init__(self,
32
- *,
33
- vals: typing.Optional[typing.Iterable[builtins.int]] = ...,
34
- ) -> None: ...
35
- def ClearField(self, field_name: typing_extensions.Literal["vals",b"vals"]) -> None: ...
36
- global___Sint64List = Sint64List
37
-
38
- class BoolList(google.protobuf.message.Message):
39
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
40
- VALS_FIELD_NUMBER: builtins.int
41
- @property
42
- def vals(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bool]: ...
43
- def __init__(self,
44
- *,
45
- vals: typing.Optional[typing.Iterable[builtins.bool]] = ...,
46
- ) -> None: ...
47
- def ClearField(self, field_name: typing_extensions.Literal["vals",b"vals"]) -> None: ...
48
- global___BoolList = BoolList
49
-
50
- class StringList(google.protobuf.message.Message):
51
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
52
- VALS_FIELD_NUMBER: builtins.int
53
- @property
54
- def vals(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[typing.Text]: ...
55
- def __init__(self,
56
- *,
57
- vals: typing.Optional[typing.Iterable[typing.Text]] = ...,
58
- ) -> None: ...
59
- def ClearField(self, field_name: typing_extensions.Literal["vals",b"vals"]) -> None: ...
60
- global___StringList = StringList
61
-
62
- class BytesList(google.protobuf.message.Message):
63
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
64
- VALS_FIELD_NUMBER: builtins.int
65
- @property
66
- def vals(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bytes]: ...
67
- def __init__(self,
68
- *,
69
- vals: typing.Optional[typing.Iterable[builtins.bytes]] = ...,
70
- ) -> None: ...
71
- def ClearField(self, field_name: typing_extensions.Literal["vals",b"vals"]) -> None: ...
72
- global___BytesList = BytesList
73
-
74
- class ConfigsRecordValue(google.protobuf.message.Message):
75
- DESCRIPTOR: google.protobuf.descriptor.Descriptor
76
- DOUBLE_FIELD_NUMBER: builtins.int
77
- SINT64_FIELD_NUMBER: builtins.int
78
- BOOL_FIELD_NUMBER: builtins.int
79
- STRING_FIELD_NUMBER: builtins.int
80
- BYTES_FIELD_NUMBER: builtins.int
81
- DOUBLE_LIST_FIELD_NUMBER: builtins.int
82
- SINT64_LIST_FIELD_NUMBER: builtins.int
83
- BOOL_LIST_FIELD_NUMBER: builtins.int
84
- STRING_LIST_FIELD_NUMBER: builtins.int
85
- BYTES_LIST_FIELD_NUMBER: builtins.int
86
- double: builtins.float
87
- """Single element"""
88
-
89
- sint64: builtins.int
90
- bool: builtins.bool
91
- string: typing.Text
92
- bytes: builtins.bytes
93
- @property
94
- def double_list(self) -> global___DoubleList:
95
- """List types"""
96
- pass
97
- @property
98
- def sint64_list(self) -> global___Sint64List: ...
99
- @property
100
- def bool_list(self) -> global___BoolList: ...
101
- @property
102
- def string_list(self) -> global___StringList: ...
103
- @property
104
- def bytes_list(self) -> global___BytesList: ...
105
- def __init__(self,
106
- *,
107
- double: builtins.float = ...,
108
- sint64: builtins.int = ...,
109
- bool: builtins.bool = ...,
110
- string: typing.Text = ...,
111
- bytes: builtins.bytes = ...,
112
- double_list: typing.Optional[global___DoubleList] = ...,
113
- sint64_list: typing.Optional[global___Sint64List] = ...,
114
- bool_list: typing.Optional[global___BoolList] = ...,
115
- string_list: typing.Optional[global___StringList] = ...,
116
- bytes_list: typing.Optional[global___BytesList] = ...,
117
- ) -> None: ...
118
- def HasField(self, field_name: typing_extensions.Literal["bool",b"bool","bool_list",b"bool_list","bytes",b"bytes","bytes_list",b"bytes_list","double",b"double","double_list",b"double_list","sint64",b"sint64","sint64_list",b"sint64_list","string",b"string","string_list",b"string_list","value",b"value"]) -> builtins.bool: ...
119
- def ClearField(self, field_name: typing_extensions.Literal["bool",b"bool","bool_list",b"bool_list","bytes",b"bytes","bytes_list",b"bytes_list","double",b"double","double_list",b"double_list","sint64",b"sint64","sint64_list",b"sint64_list","string",b"string","string_list",b"string_list","value",b"value"]) -> None: ...
120
- def WhichOneof(self, oneof_group: typing_extensions.Literal["value",b"value"]) -> typing.Optional[typing_extensions.Literal["double","sint64","bool","string","bytes","double_list","sint64_list","bool_list","string_list","bytes_list"]]: ...
121
- global___ConfigsRecordValue = ConfigsRecordValue
@@ -1,4 +0,0 @@
1
- # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
- """Client and server classes corresponding to protobuf-defined services."""
3
- import grpc
4
-
@@ -1,4 +0,0 @@
1
- """
2
- @generated by mypy-protobuf. Do not edit manually!
3
- isort:skip_file
4
- """
flwr/proto/control_pb2.py DELETED
@@ -1,27 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # source: flwr/proto/control.proto
4
- # Protobuf Python Version: 4.25.0
5
- """Generated protocol buffer code."""
6
- from google.protobuf import descriptor as _descriptor
7
- from google.protobuf import descriptor_pool as _descriptor_pool
8
- from google.protobuf import symbol_database as _symbol_database
9
- from google.protobuf.internal import builder as _builder
10
- # @@protoc_insertion_point(imports)
11
-
12
- _sym_db = _symbol_database.Default()
13
-
14
-
15
- from flwr.proto import run_pb2 as flwr_dot_proto_dot_run__pb2
16
-
17
-
18
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x18\x66lwr/proto/control.proto\x12\nflwr.proto\x1a\x14\x66lwr/proto/run.proto2\x88\x02\n\x07\x43ontrol\x12J\n\tCreateRun\x12\x1c.flwr.proto.CreateRunRequest\x1a\x1d.flwr.proto.CreateRunResponse\"\x00\x12S\n\x0cGetRunStatus\x12\x1f.flwr.proto.GetRunStatusRequest\x1a .flwr.proto.GetRunStatusResponse\"\x00\x12\\\n\x0fUpdateRunStatus\x12\".flwr.proto.UpdateRunStatusRequest\x1a#.flwr.proto.UpdateRunStatusResponse\"\x00\x62\x06proto3')
19
-
20
- _globals = globals()
21
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
22
- _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'flwr.proto.control_pb2', _globals)
23
- if _descriptor._USE_C_DESCRIPTORS == False:
24
- DESCRIPTOR._options = None
25
- _globals['_CONTROL']._serialized_start=63
26
- _globals['_CONTROL']._serialized_end=327
27
- # @@protoc_insertion_point(module_scope)
@@ -1,7 +0,0 @@
1
- """
2
- @generated by mypy-protobuf. Do not edit manually!
3
- isort:skip_file
4
- """
5
- import google.protobuf.descriptor
6
-
7
- DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
@@ -1,135 +0,0 @@
1
- # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
- """Client and server classes corresponding to protobuf-defined services."""
3
- import grpc
4
-
5
- from flwr.proto import run_pb2 as flwr_dot_proto_dot_run__pb2
6
-
7
-
8
- class ControlStub(object):
9
- """Missing associated documentation comment in .proto file."""
10
-
11
- def __init__(self, channel):
12
- """Constructor.
13
-
14
- Args:
15
- channel: A grpc.Channel.
16
- """
17
- self.CreateRun = channel.unary_unary(
18
- '/flwr.proto.Control/CreateRun',
19
- request_serializer=flwr_dot_proto_dot_run__pb2.CreateRunRequest.SerializeToString,
20
- response_deserializer=flwr_dot_proto_dot_run__pb2.CreateRunResponse.FromString,
21
- )
22
- self.GetRunStatus = channel.unary_unary(
23
- '/flwr.proto.Control/GetRunStatus',
24
- request_serializer=flwr_dot_proto_dot_run__pb2.GetRunStatusRequest.SerializeToString,
25
- response_deserializer=flwr_dot_proto_dot_run__pb2.GetRunStatusResponse.FromString,
26
- )
27
- self.UpdateRunStatus = channel.unary_unary(
28
- '/flwr.proto.Control/UpdateRunStatus',
29
- request_serializer=flwr_dot_proto_dot_run__pb2.UpdateRunStatusRequest.SerializeToString,
30
- response_deserializer=flwr_dot_proto_dot_run__pb2.UpdateRunStatusResponse.FromString,
31
- )
32
-
33
-
34
- class ControlServicer(object):
35
- """Missing associated documentation comment in .proto file."""
36
-
37
- def CreateRun(self, request, context):
38
- """Request to create a new run
39
- """
40
- context.set_code(grpc.StatusCode.UNIMPLEMENTED)
41
- context.set_details('Method not implemented!')
42
- raise NotImplementedError('Method not implemented!')
43
-
44
- def GetRunStatus(self, request, context):
45
- """Get the status of a given run
46
- """
47
- context.set_code(grpc.StatusCode.UNIMPLEMENTED)
48
- context.set_details('Method not implemented!')
49
- raise NotImplementedError('Method not implemented!')
50
-
51
- def UpdateRunStatus(self, request, context):
52
- """Update the status of a given run
53
- """
54
- context.set_code(grpc.StatusCode.UNIMPLEMENTED)
55
- context.set_details('Method not implemented!')
56
- raise NotImplementedError('Method not implemented!')
57
-
58
-
59
- def add_ControlServicer_to_server(servicer, server):
60
- rpc_method_handlers = {
61
- 'CreateRun': grpc.unary_unary_rpc_method_handler(
62
- servicer.CreateRun,
63
- request_deserializer=flwr_dot_proto_dot_run__pb2.CreateRunRequest.FromString,
64
- response_serializer=flwr_dot_proto_dot_run__pb2.CreateRunResponse.SerializeToString,
65
- ),
66
- 'GetRunStatus': grpc.unary_unary_rpc_method_handler(
67
- servicer.GetRunStatus,
68
- request_deserializer=flwr_dot_proto_dot_run__pb2.GetRunStatusRequest.FromString,
69
- response_serializer=flwr_dot_proto_dot_run__pb2.GetRunStatusResponse.SerializeToString,
70
- ),
71
- 'UpdateRunStatus': grpc.unary_unary_rpc_method_handler(
72
- servicer.UpdateRunStatus,
73
- request_deserializer=flwr_dot_proto_dot_run__pb2.UpdateRunStatusRequest.FromString,
74
- response_serializer=flwr_dot_proto_dot_run__pb2.UpdateRunStatusResponse.SerializeToString,
75
- ),
76
- }
77
- generic_handler = grpc.method_handlers_generic_handler(
78
- 'flwr.proto.Control', rpc_method_handlers)
79
- server.add_generic_rpc_handlers((generic_handler,))
80
-
81
-
82
- # This class is part of an EXPERIMENTAL API.
83
- class Control(object):
84
- """Missing associated documentation comment in .proto file."""
85
-
86
- @staticmethod
87
- def CreateRun(request,
88
- target,
89
- options=(),
90
- channel_credentials=None,
91
- call_credentials=None,
92
- insecure=False,
93
- compression=None,
94
- wait_for_ready=None,
95
- timeout=None,
96
- metadata=None):
97
- return grpc.experimental.unary_unary(request, target, '/flwr.proto.Control/CreateRun',
98
- flwr_dot_proto_dot_run__pb2.CreateRunRequest.SerializeToString,
99
- flwr_dot_proto_dot_run__pb2.CreateRunResponse.FromString,
100
- options, channel_credentials,
101
- insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
102
-
103
- @staticmethod
104
- def GetRunStatus(request,
105
- target,
106
- options=(),
107
- channel_credentials=None,
108
- call_credentials=None,
109
- insecure=False,
110
- compression=None,
111
- wait_for_ready=None,
112
- timeout=None,
113
- metadata=None):
114
- return grpc.experimental.unary_unary(request, target, '/flwr.proto.Control/GetRunStatus',
115
- flwr_dot_proto_dot_run__pb2.GetRunStatusRequest.SerializeToString,
116
- flwr_dot_proto_dot_run__pb2.GetRunStatusResponse.FromString,
117
- options, channel_credentials,
118
- insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
119
-
120
- @staticmethod
121
- def UpdateRunStatus(request,
122
- target,
123
- options=(),
124
- channel_credentials=None,
125
- call_credentials=None,
126
- insecure=False,
127
- compression=None,
128
- wait_for_ready=None,
129
- timeout=None,
130
- metadata=None):
131
- return grpc.experimental.unary_unary(request, target, '/flwr.proto.Control/UpdateRunStatus',
132
- flwr_dot_proto_dot_run__pb2.UpdateRunStatusRequest.SerializeToString,
133
- flwr_dot_proto_dot_run__pb2.UpdateRunStatusResponse.FromString,
134
- options, channel_credentials,
135
- insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
@@ -1,53 +0,0 @@
1
- """
2
- @generated by mypy-protobuf. Do not edit manually!
3
- isort:skip_file
4
- """
5
- import abc
6
- import flwr.proto.run_pb2
7
- import grpc
8
-
9
- class ControlStub:
10
- def __init__(self, channel: grpc.Channel) -> None: ...
11
- CreateRun: grpc.UnaryUnaryMultiCallable[
12
- flwr.proto.run_pb2.CreateRunRequest,
13
- flwr.proto.run_pb2.CreateRunResponse]
14
- """Request to create a new run"""
15
-
16
- GetRunStatus: grpc.UnaryUnaryMultiCallable[
17
- flwr.proto.run_pb2.GetRunStatusRequest,
18
- flwr.proto.run_pb2.GetRunStatusResponse]
19
- """Get the status of a given run"""
20
-
21
- UpdateRunStatus: grpc.UnaryUnaryMultiCallable[
22
- flwr.proto.run_pb2.UpdateRunStatusRequest,
23
- flwr.proto.run_pb2.UpdateRunStatusResponse]
24
- """Update the status of a given run"""
25
-
26
-
27
- class ControlServicer(metaclass=abc.ABCMeta):
28
- @abc.abstractmethod
29
- def CreateRun(self,
30
- request: flwr.proto.run_pb2.CreateRunRequest,
31
- context: grpc.ServicerContext,
32
- ) -> flwr.proto.run_pb2.CreateRunResponse:
33
- """Request to create a new run"""
34
- pass
35
-
36
- @abc.abstractmethod
37
- def GetRunStatus(self,
38
- request: flwr.proto.run_pb2.GetRunStatusRequest,
39
- context: grpc.ServicerContext,
40
- ) -> flwr.proto.run_pb2.GetRunStatusResponse:
41
- """Get the status of a given run"""
42
- pass
43
-
44
- @abc.abstractmethod
45
- def UpdateRunStatus(self,
46
- request: flwr.proto.run_pb2.UpdateRunStatusRequest,
47
- context: grpc.ServicerContext,
48
- ) -> flwr.proto.run_pb2.UpdateRunStatusResponse:
49
- """Update the status of a given run"""
50
- pass
51
-
52
-
53
- def add_ControlServicer_to_server(servicer: ControlServicer, server: grpc.Server) -> None: ...