Skip to content

Commit

Permalink
Add missing type
Browse files Browse the repository at this point in the history
  • Loading branch information
charlesbvll committed Jul 6, 2024
1 parent bb9cf31 commit 3ccc2df
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/py/flwr/common/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

import os
from pathlib import Path
from typing import Any, Dict, Optional, Union, cast
from typing import Any, Dict, List, Optional, Tuple, Union

import tomli

Expand Down Expand Up @@ -77,7 +77,7 @@ def get_project_config(project_dir: Union[str, Path]) -> Dict[str, Any]:
def _flatten_dict(
raw_dict: Dict[str, Any], sep: str = "."
) -> Dict[str, ConfigsRecordValues]:
items = []
items: List[Tuple[str, ConfigsRecordValues]] = []
for k, v in raw_dict.items():
if isinstance(v, dict):
items.extend(_flatten_dict(v, sep=sep).items())
Expand Down Expand Up @@ -108,4 +108,4 @@ def get_fused_config(
else:
final_config[key] = default_config[key]

return cast(Dict[str, ConfigsRecordValues], final_config)
return final_config

0 comments on commit 3ccc2df

Please sign in to comment.