Closed cisaacstern closed 1 month ago
The json provided in this comment is one reference point for what this data structure looks like:
https://github.com/wildlife-dynamics/ecoscope-workflows/pull/45#issuecomment-2231489970
The react-jsonschema-form playground is liked at the bottom of that comment, which is a very useful reference.
The more I am thinking about this the more I wonder if the best way to approach this is:
It would be an interesting thought experiment to see if all of the user-configurable parameters we currently have for our tasks could be expressed within these constraints.
If/when they cannot, we have at least two paths of recourse:
duplicate of #93, closing
Pydantic allows us to customize json schema output.
Now that @juanlescano-ng has identified react-jsonschema-form as the form generator for the front end, we will need to make sure our JSON schema (as output by the 'get-params' command) conforms to this expectation.
Certain Python/pydnatic field types may not fit a data type supported by react-jsonschema-forms, which highlights the importance of testing JSON Schema generation for all newly added (and existing) tasks.
Among other things, options for handling data types that don't directly parse into compatible JSON schema include: