Skip to content

Conversation

jefflembeck
Copy link

closes #1569

BREAKING CHANGE: Validation error messages for unions/intersections are now summarized when they exceed size limits

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you written unit tests?
  • Have you written unit tests that cover the negative cases (i.e.: if bad data is submitted, does the library respond properly)?
  • This PR is associated with an existing issue?

Closing issues

Put closes #XXXX (where XXXX is the issue number) in your comment to auto-close the issue that your PR fixes.

If this is a new feature submission:

  • Has the issue had a maintainer respond to the issue and clarify that the feature is something that aligns with the goals and philosophy of the project?

Potential Problems With The Approach

Test plan

- Replace JSON.parse/stringify with proper deepClone to avoid exponential
escaping
- Add summarizeValidationErrors to limit error message size
- Add maxValidationErrorSize configuration option
- Fix issue lukeautry#1569 where validation errors could grow to 28KB-300MB

BREAKING CHANGE: Validation error messages for unions/intersections are
now summarized when they exceed size limits
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problem with validation when dealing with unions and deep models
1 participant