Skip to content

Commit c7b0414

Browse files
author
root
committed
fix tests
1 parent 3f15919 commit c7b0414

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

fastdeploy/engine/args_utils.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1065,7 +1065,11 @@ def from_cli_args(cls, args: FlexibleArgumentParser) -> "EngineArgs":
10651065
"""
10661066
Create an instance of EngineArgs from command line arguments.
10671067
"""
1068-
return cls(**{field.name: getattr(args, field.name) for field in dataclass_fields(cls)})
1068+
args_dict = {}
1069+
for field in dataclass_fields(cls):
1070+
if hasattr(args, field.name):
1071+
args_dict[field.name] = getattr(args, field.name)
1072+
return cls(**args_dict)
10691073

10701074
def create_speculative_config(self) -> SpeculativeConfig:
10711075
""" """

0 commit comments

Comments
 (0)