Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
e3rd committed Sep 25, 2024
1 parent a30b8df commit 0c94a0f
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions mininterface/cli_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,11 @@ def run_tyro_parser(env_class: Type[EnvClass],
else:
# get the original attribute name (argparse uses dash instead of underscores)
field_name = argument.dest
if field_name not in env_class.__annotations__:
field_name = field_name.replace("-", "_")
if field_name not in env_class.__annotations__:
raise ValueError(f"Cannot find {field_name} in the configuration object")
# TODO
# if field_name not in env_class.__annotations__:
# field_name = field_name.replace("-", "_")
# if field_name not in env_class.__annotations__:
# raise ValueError(f"Cannot find {field_name} in the configuration object")

# NOTE: We put '' to the UI to clearly state that the value is missing.
# However, the UI then is not able to use the number filtering capabilities.
Expand Down

0 comments on commit 0c94a0f

Please sign in to comment.