add float support

This commit is contained in:
Emmanuel Garette 2020-03-20 22:19:10 +01:00
parent 505af25995
commit c13da02553
1 changed files with 2 additions and 0 deletions

View File

@ -545,6 +545,8 @@ class TiramisuCmdlineParser(ArgumentParser):
elif option.type() == 'choice' and not option.isfollower(): elif option.type() == 'choice' and not option.isfollower():
# do not manage choice with argparse there is problem with integer problem # do not manage choice with argparse there is problem with integer problem
kwargs['choices'] = get_choice_list(obj, properties, False) kwargs['choices'] = get_choice_list(obj, properties, False)
elif option.type() == 'float':
kwargs['type'] = float
else: else:
pass pass
actions.setdefault(option.name(), []).append(kwargs) actions.setdefault(option.name(), []).append(kwargs)