flwr-nightly 1.9.0.dev20240416__py3-none-any.whl → 1.9.0.dev20240417__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.

@@ -12,7 +12,7 @@
12
12
  # See the License for the specific language governing permissions and
13
13
  # limitations under the License.
14
14
  # ==============================================================================
15
- """Utility to validate the `flower.toml` file."""
15
+ """Utility to validate the `pyproject.toml` file."""
16
16
 
17
17
  import os
18
18
  from typing import Any, Dict, List, Optional, Tuple
@@ -25,7 +25,7 @@ from flwr.common import object_ref
25
25
  def load_and_validate_with_defaults(
26
26
  path: Optional[str] = None,
27
27
  ) -> Tuple[Optional[Dict[str, Any]], List[str], List[str]]:
28
- """Load and validate flower.toml as dict.
28
+ """Load and validate pyproject.toml as dict.
29
29
 
30
30
  Returns
31
31
  -------
@@ -37,7 +37,7 @@ def load_and_validate_with_defaults(
37
37
 
38
38
  if config is None:
39
39
  errors = [
40
- "Project configuration could not be loaded. flower.toml does not exist."
40
+ "Project configuration could not be loaded. pyproject.toml does not exist."
41
41
  ]
42
42
  return (None, errors, [])
43
43
 
@@ -58,10 +58,10 @@ def load_and_validate_with_defaults(
58
58
 
59
59
 
60
60
  def load(path: Optional[str] = None) -> Optional[Dict[str, Any]]:
61
- """Load flower.toml and return as dict."""
61
+ """Load pyproject.toml and return as dict."""
62
62
  if path is None:
63
63
  cur_dir = os.getcwd()
64
- toml_path = os.path.join(cur_dir, "flower.toml")
64
+ toml_path = os.path.join(cur_dir, "pyproject.toml")
65
65
  else:
66
66
  toml_path = path
67
67
 
@@ -74,7 +74,7 @@ def load(path: Optional[str] = None) -> Optional[Dict[str, Any]]:
74
74
 
75
75
 
76
76
  def validate_fields(config: Dict[str, Any]) -> Tuple[bool, List[str], List[str]]:
77
- """Validate flower.toml fields."""
77
+ """Validate pyproject.toml fields."""
78
78
  errors = []
79
79
  warnings = []
80
80
 
@@ -106,7 +106,7 @@ def validate_fields(config: Dict[str, Any]) -> Tuple[bool, List[str], List[str]]
106
106
 
107
107
 
108
108
  def validate(config: Dict[str, Any]) -> Tuple[bool, List[str], List[str]]:
109
- """Validate flower.toml."""
109
+ """Validate pyproject.toml."""
110
110
  is_valid, errors, warnings = validate_fields(config)
111
111
 
112
112
  if not is_valid:
flwr/cli/new/new.py CHANGED
@@ -128,7 +128,6 @@ def new(
128
128
  # List of files to render
129
129
  files = {
130
130
  "README.md": {"template": "app/README.md.tpl"},
131
- "flower.toml": {"template": "app/flower.toml.tpl"},
132
131
  "pyproject.toml": {"template": f"app/pyproject.{framework_str}.toml.tpl"},
133
132
  f"{pnl}/__init__.py": {"template": "app/code/__init__.py.tpl"},
134
133
  f"{pnl}/server.py": {"template": f"app/code/server.{framework_str}.py.tpl"},
@@ -17,3 +17,7 @@ dependencies = [
17
17
 
18
18
  [tool.hatch.build.targets.wheel]
19
19
  packages = ["."]
20
+
21
+ [flower.components]
22
+ serverapp = "$project_name.server:app"
23
+ clientapp = "$project_name.client:app"
@@ -19,3 +19,7 @@ dependencies = [
19
19
 
20
20
  [tool.hatch.build.targets.wheel]
21
21
  packages = ["."]
22
+
23
+ [flower.components]
24
+ serverapp = "$project_name.server:app"
25
+ clientapp = "$project_name.client:app"
@@ -18,3 +18,7 @@ dependencies = [
18
18
 
19
19
  [tool.hatch.build.targets.wheel]
20
20
  packages = ["."]
21
+
22
+ [flower.components]
23
+ serverapp = "$project_name.server:app"
24
+ clientapp = "$project_name.client:app"
flwr/cli/run/run.py CHANGED
@@ -18,7 +18,7 @@ import sys
18
18
 
19
19
  import typer
20
20
 
21
- from flwr.cli import flower_toml
21
+ from flwr.cli import config_utils
22
22
  from flwr.simulation.run_simulation import _run_simulation
23
23
 
24
24
 
@@ -26,7 +26,7 @@ def run() -> None:
26
26
  """Run Flower project."""
27
27
  typer.secho("Loading project configuration... ", fg=typer.colors.BLUE)
28
28
 
29
- config, errors, warnings = flower_toml.load_and_validate_with_defaults()
29
+ config, errors, warnings = config_utils.load_and_validate_with_defaults()
30
30
 
31
31
  if config is None:
32
32
  typer.secho(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: flwr-nightly
3
- Version: 1.9.0.dev20240416
3
+ Version: 1.9.0.dev20240417
4
4
  Summary: Flower: A Friendly Federated Learning Framework
5
5
  Home-page: https://flower.ai
6
6
  License: Apache-2.0
@@ -1,10 +1,10 @@
1
1
  flwr/__init__.py,sha256=VmBWedrCxqmt4QvUHBLqyVEH6p7zaFMD_oCHerXHSVw,937
2
2
  flwr/cli/__init__.py,sha256=cZJVgozlkC6Ni2Hd_FAIrqefrkCGOV18fikToq-6iLw,720
3
3
  flwr/cli/app.py,sha256=38thPnMydBmNAxNE9mz4By-KdRUhJfoUgeDuAxMYF_U,1095
4
+ flwr/cli/config_utils.py,sha256=fTKBxsXauE8JWdwTb8yLxOm69sAcURefoif-DGUDNII,4696
4
5
  flwr/cli/example.py,sha256=1bGDYll3BXQY2kRqSN-oICqS5n1b9m0g0RvXTopXHl4,2215
5
- flwr/cli/flower_toml.py,sha256=gypY4zOe6Mx_Xzz5vsSzGRppWBaCnipiksBTrox_r3k,4675
6
6
  flwr/cli/new/__init__.py,sha256=cQzK1WH4JP2awef1t2UQ2xjl1agVEz9rwutV18SWV1k,789
7
- flwr/cli/new/new.py,sha256=gxl4j0b9Ojsh5vcjmwPxEY4wrxDQg8JaLs7-Q61xvFM,5300
7
+ flwr/cli/new/new.py,sha256=raXLXtYfDG0XVcmHfDAvWN9Q5q65sC46SZ-1ICb9ChE,5240
8
8
  flwr/cli/new/templates/__init__.py,sha256=4luU8RL-CK8JJCstQ_ON809W9bNTkY1l9zSaPKBkgwY,725
9
9
  flwr/cli/new/templates/app/README.md.tpl,sha256=_qGtgpKYKoCJVjQnvlBMKvFs_1gzTcL908I3KJg0oAM,668
10
10
  flwr/cli/new/templates/app/__init__.py,sha256=DU7QMY7IhMQyuwm_tja66xU0KXTWQFqzfTqwg-_NJdE,729
@@ -17,12 +17,11 @@ flwr/cli/new/templates/app/code/server.numpy.py.tpl,sha256=fRxrDXV7pB1aDhQUXMBmr
17
17
  flwr/cli/new/templates/app/code/server.pytorch.py.tpl,sha256=xtKvUivNMzgOcLSOtnjWouJzIFbXdUQVYMm27uwyJpI,594
18
18
  flwr/cli/new/templates/app/code/server.tensorflow.py.tpl,sha256=d6J5VM681d0j4hj1Duaj1WQyeFoyCiEZh4o4J8zH-_M,48
19
19
  flwr/cli/new/templates/app/code/task.pytorch.py.tpl,sha256=NvajdZN-eTyfdqKK0v2MrvWITXw9BjJ3Ri5c1haPJDs,3684
20
- flwr/cli/new/templates/app/flower.toml.tpl,sha256=gJ5MZ7zaiaVvIEt5X_kkU-SU2NmeXkAZ9NXJS00-Axw,269
21
- flwr/cli/new/templates/app/pyproject.numpy.toml.tpl,sha256=00Qp7cQhOvW0Bx7j82mIP9BXT6D0ysbzqZHDEPoZQyU,390
22
- flwr/cli/new/templates/app/pyproject.pytorch.toml.tpl,sha256=A2AqU5lh2VBHOCX_S7rTMYZc5JmPqwEVIg9KsIjLgh8,459
23
- flwr/cli/new/templates/app/pyproject.tensorflow.toml.tpl,sha256=vLmeOFCIvMVUoIDgGtLinAUQy6jKjqmgHKcuEqhVYkw,438
20
+ flwr/cli/new/templates/app/pyproject.numpy.toml.tpl,sha256=0oTH0lY7q-PpRV4HA5woxJ1eWIgZRFcFsHa7-1lULIQ,489
21
+ flwr/cli/new/templates/app/pyproject.pytorch.toml.tpl,sha256=GYbMAFD90JBRvy8fJbLU7nDITD3sxHv1TncQrg6mjEE,558
22
+ flwr/cli/new/templates/app/pyproject.tensorflow.toml.tpl,sha256=7I8BYtE28cnc7ZiOlOp6_zeLsjLRlwa0Y4sjoP7r9VU,537
24
23
  flwr/cli/run/__init__.py,sha256=oCd6HmQDx-sqver1gecgx-uMA38BLTSiiKpl7RGNceg,789
25
- flwr/cli/run/run.py,sha256=C7Yh-Y0f64PEabb9733jBKIhhOUFpcRmCZJIDtv-NG8,2329
24
+ flwr/cli/run/run.py,sha256=qxXgShEXHONx-Gjpl515HF60QzRA-Ygpj2sbl0bZUAA,2331
26
25
  flwr/cli/utils.py,sha256=33m5ELefA43VhJwtBHW5ntWkP7X5Tk_5A2s1OcaSBYg,4153
27
26
  flwr/client/__init__.py,sha256=futk_IdY_N1h8BTve4Iru51bxm7H1gv58ZPIXWi5XUA,1187
28
27
  flwr/client/app.py,sha256=B48cQa-kb_0WzdtufTXuaoEyrynGWMQCqxdUz_sAKek,26193
@@ -203,8 +202,8 @@ flwr/simulation/ray_transport/ray_actor.py,sha256=_wv2eP7qxkCZ-6rMyYWnjLrGPBZRxj
203
202
  flwr/simulation/ray_transport/ray_client_proxy.py,sha256=oDu4sEPIOu39vrNi-fqDAe10xtNUXMO49bM2RWfRcyw,6738
204
203
  flwr/simulation/ray_transport/utils.py,sha256=TYdtfg1P9VfTdLMOJlifInGpxWHYs9UfUqIv2wfkRLA,2392
205
204
  flwr/simulation/run_simulation.py,sha256=HiIH6aa_v56NfKQN5ZBd94NyVfaZNyFs43_kItYsQXU,15685
206
- flwr_nightly-1.9.0.dev20240416.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
207
- flwr_nightly-1.9.0.dev20240416.dist-info/METADATA,sha256=OJeC2fIcMuJ2PuYVGFMOZ7FzxDf4lQkX666xeoiEiow,15260
208
- flwr_nightly-1.9.0.dev20240416.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
209
- flwr_nightly-1.9.0.dev20240416.dist-info/entry_points.txt,sha256=utu2wybGyYJSTtsB2ktY_gmy-XtMFo9EFZdishX0zR4,320
210
- flwr_nightly-1.9.0.dev20240416.dist-info/RECORD,,
205
+ flwr_nightly-1.9.0.dev20240417.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
206
+ flwr_nightly-1.9.0.dev20240417.dist-info/METADATA,sha256=6gwoKexzP8jcUYS-mCm47XnZsuPhO06R1b-vqBipQCM,15260
207
+ flwr_nightly-1.9.0.dev20240417.dist-info/WHEEL,sha256=FMvqSimYX_P7y0a7UY-_Mc83r5zkBZsCYPm7Lr0Bsq4,88
208
+ flwr_nightly-1.9.0.dev20240417.dist-info/entry_points.txt,sha256=utu2wybGyYJSTtsB2ktY_gmy-XtMFo9EFZdishX0zR4,320
209
+ flwr_nightly-1.9.0.dev20240417.dist-info/RECORD,,
@@ -1,13 +0,0 @@
1
- [project]
2
- name = "$project_name"
3
- version = "1.0.0"
4
- description = ""
5
- license = "Apache-2.0"
6
- authors = [
7
- "The Flower Authors <hello@flower.ai>",
8
- ]
9
- readme = "README.md"
10
-
11
- [flower.components]
12
- serverapp = "$project_name.server:app"
13
- clientapp = "$project_name.client:app"