mirror of
https://github.com/All-Hands-AI/OpenHands.git
synced 2026-01-10 07:18:10 -05:00
committed by
GitHub
parent
5244a34a1d
commit
24e61ead65
@@ -192,7 +192,7 @@ def load_from_env(config: AppConfig, env_or_toml_dict: dict | os._Environ):
|
||||
|
||||
# Attempt to cast the env var to type hinted in the dataclass
|
||||
if field_type is bool:
|
||||
cast_value = value.lower() in ['true', '1']
|
||||
cast_value = str(value).lower() in ['true', '1']
|
||||
else:
|
||||
cast_value = field_type(value)
|
||||
setattr(sub_config, field_name, cast_value)
|
||||
|
||||
Reference in New Issue
Block a user