Closed saleemjaffer closed 6 years ago
I do not have enough info here to address this in particular without an http://sscce.org/
That said, I have done a bunch of work on the Json.Decode
library to produce nicer error messages. Ones that people can customize to show things however they want. So my recommendation would be to see if it's as bad in 0.19, and if so, open an issue on the elm-lang/json
repo with an SSCCE.
Sorry for the difficulty in the meantime, and thank you for letting us know!
I have a JSON where the value for a key is be nullable. The value for this key is a complex-ish JSON object. If the value is an incorrect JSON, the decoder fails and the compiler just complains saying
The value is expected to be null but it is ...
. It is hard to figure out what actually is wrong since the JSON is complex. Can we get a better error message for this?I use Json.Decode.nullable to decode this nullable JSON.