Right now you can accept arbitrary metadata using the JSON
scalar, which is great. But sometimes the json has a specific structure, for example: JSON[dict[str, int]]
and it would be great if you could add type hints like that to validate the incoming data.
This could hopefully also get around the linting errors like
Expression of type "dict[str, str]" cannot be assigned to declared type "JSON"
and
Expected mapping for dictionary unpack operator
(when trying to do {**some_json_input}
)
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too