FastUI
FastUI copied to clipboard
Single value literal doesn't work in select form
To reproduce this issue, just change the ToolEnum to Literal of ToolEnum.hammer in demo source code.
Error trace
File "/Users/manimozaffar/Desktop/fastui/src/python-fastui/fastui/json_schema.py", line 157, in json_schema_obj_to_fields
yield from json_schema_any_to_fields(value, loc + [key], title, key in required, defs)
File "/Users/manimozaffar/Desktop/fastui/src/python-fastui/fastui/json_schema.py", line 166, in json_schema_any_to_fields
if schema_is_field(schema):
^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/manimozaffar/Desktop/fastui/src/python-fastui/fastui/json_schema.py", line 379, in schema_is_field
return schema['type'] in {'string', 'number', 'integer', 'boolean'}
~~~~~~^^^^^^^^
KeyError: 'type'