Skip to content

Commit

Permalink
provided a useful warning if old parameter (bootdisksizegb) specified
Browse files Browse the repository at this point in the history
  • Loading branch information
pgm committed Oct 2, 2024
1 parent 1208829 commit 8befed5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cli/sparklespray/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,12 @@ def load_config(

config_dict.update(overrides)

# check for deprecated options
if "bootdisksizegb" in config_dict:
print("Warning: The option \"bootdisksizegb\" was seen in the config file but this name is deprecated. This parameter has been replaced with boot_volume_in_gb.")
config_dict["boot_volume_in_gb"] = config_dict["bootdisksizegb"]
del config_dict["bootdisksizegb"]

config_used = set()
def consume(name: str, default : Union[NoDefault, T]=NO_DEFAULT, parser : Callable[[str], T]=str) -> T:
assert name not in config_used, f"Consumed {name} twice"
Expand Down

0 comments on commit 8befed5

Please sign in to comment.