Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: properly handle circular regressions to prevent call stack exceptions #253

Merged
merged 1 commit into from
Mar 1, 2021

Conversation

dpopp07
Copy link
Member

@dpopp07 dpopp07 commented Feb 26, 2021

A regression was recently introduced to the validator in the circular references
utility that prevented such references from being caught and sanitized. This resulted
in "call stack exceeded" exceptions for certain patterns using circular references.

The regression came in the form of checking for only "plain" objects, rather than
all "objects" (which include arrays). This happened in a recent community PR and I
didn't realize the consequences when I reviewed and merged. I went back and double
checked every instance of this change in that PR and believe this is the only one
that is problematic. I fixed it and added a new test case that would've caught this
regression had it been there.

Resolves #251

…tions

A regression was recently introduced to the validator in the circular references
utility that prevented such references from being caught and sanitized. This resulted
in "call stack exceeded" expections for certain patterns using circular references.

The regression came in the form of checking for only "plain" objects, rather than
all "objects" (which include arrays). This happened in a recent community PR and I
didn't realize the consequences when I reviewed and merged. I went back and double
checked every instance of this change in that PR and believe this is the only one
that is problematic. I fixed it and added a new test case that would've caught this
regression had it been there.
Copy link
Contributor

@barrett-schonefeld barrett-schonefeld left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look good and a great, convincing test!

Copy link
Contributor

@mkistler mkistler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍

@dpopp07 dpopp07 merged commit 3696487 into main Mar 1, 2021
@dpopp07 dpopp07 deleted the dp/fix-call-stack-regression branch March 1, 2021 18:45
dpopp07 pushed a commit that referenced this pull request Mar 1, 2021
## [0.34.4](v0.34.3...v0.34.4) (2021-03-01)

### Bug Fixes

* properly handle circular regressions to prevent call stack exceptions ([#253](#253)) ([3696487](3696487))
@dpopp07
Copy link
Member Author

dpopp07 commented Mar 1, 2021

🎉 This PR is included in version 0.34.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression: "Maximum call stack size exceeded" is back
3 participants