Add multiple error returning in JSON Serializing #109372
Replies: 2 comments 4 replies
-
My immediate thought on why it works as it currently does is that, especially for formatting errors, such as missing commas or other unexpected tokens, once a single error is found, everything else is an error, because the reader no longer knows what to expect next. |
Beta Was this translation helpful? Give feedback.
-
JSON syntax errors should fail fast. On the first unexpected or unhandled token. Semantic errors during serialisation? I can imagine how you could continue after the first error and fail at the end. But that's a significant change to the serialisation interface. Including all custom |
Beta Was this translation helpful? Give feedback.
-
Hi everyone,
This is my first discussion in my career, and I’m excited to contribute an idea.
While working with JSON serialization, I encountered a scenario where the JSON had multiple errors. Currently, the serializer identifies one error at a time, which requires multiple iterations to find and fix all issues. I believe it would be beneficial if the serializer could return all errors in one go, which could greatly improve the debugging process.
This change would save time and make it easier for developers to resolve JSON issues quickly. I'd love to hear your thoughts on this idea!
Here is an example to simplify what I'am trying to say:
Beta Was this translation helpful? Give feedback.
All reactions