WIP: Expand the developer documentation #27

Draft
gremond wants to merge 189 commits from develop into developer_docs
Showing only changes of commit e77b65ffd5 - Show all commits

View file

@ -468,11 +468,14 @@ def convert_value(option, value, needs_convert):
except:
return value
if option_type == "choice":
choices = option.value.list()
if value not in choices and isinstance(value, str):
# FIXME add other tests (boolean, float, ...)
if value.isnumeric() and int(value) in choices:
value = int(value)
try:
choices = option.value.list()
if value not in choices and isinstance(value, str):
# FIXME add other tests (boolean, float, ...)
if value.isnumeric() and int(value) in choices:
value = int(value)
except:
pass
func = CONVERT_OPTION.get(option_type, {}).get("func")
if func:
try: