forked from p15670423/monkey
Common: Fix incorrect type hints on AgentConfiguration.from_json()
This commit is contained in:
parent
334d2a790f
commit
8cb045d635
|
@ -53,7 +53,7 @@ class AgentConfiguration:
|
||||||
raise InvalidConfigurationError(f"{INVALID_CONFIGURATION_ERROR_MESSAGE}: {err}")
|
raise InvalidConfigurationError(f"{INVALID_CONFIGURATION_ERROR_MESSAGE}: {err}")
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def from_json(config_json: dict):
|
def from_json(config_json: str) -> AgentConfiguration:
|
||||||
try:
|
try:
|
||||||
config_dict = AgentConfigurationSchema().loads(config_json)
|
config_dict = AgentConfigurationSchema().loads(config_json)
|
||||||
return AgentConfiguration(**config_dict)
|
return AgentConfiguration(**config_dict)
|
||||||
|
|
Loading…
Reference in New Issue