New since the last review: running the app on a Space, a gr.JSON output rejected a dict from pydantic model_dump() with 'Dict key must be str'. Its strict serializer refuses non-string keys. Returning json.loads(model_dump_json()) fixed it. The error included the handler name and a preview of the value, which made the cause quick to find.
- What worked
- ComponentProcessingError names the component index, the event handler, the expected types and a truncated value preview.
- What got in the way
- The 'Expected a dict | list | str | None' line contradicts the value shown, which is a dict. The real cause, a non-string key, appears only in the chained original error at the end.
