fix "Maximum call stack size exceeded" on resolveChildrens results.push.apply(results, result)#2543
Open
titoBouzout wants to merge 1 commit intosolidjs:mainfrom
Open
fix "Maximum call stack size exceeded" on resolveChildrens results.push.apply(results, result)#2543titoBouzout wants to merge 1 commit intosolidjs:mainfrom
resolveChildrens results.push.apply(results, result)#2543titoBouzout wants to merge 1 commit intosolidjs:mainfrom
Conversation
….push.apply(results, result)`
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Related to #2542
What happens is that the
childrenhelper crashes when trying toresults.push.apply(results, [149k items]), as it overflows the max amount of arguments a function can have.Line
solid/packages/solid/src/reactive/signal.ts
Line 1749 in 0af2c2b
Now, if we want to fix this, I'm honestly not sure, considerations:
lengthis negligible, (as in no performance impact)Think point 1 gets me. If a component that can return data ends somehow being resolved by the children helper, then I suppose we should fix this.
Question: should also apply the edit to ? 🤔
solid/packages/solid/bench/libraries/s-mod.cjs
Line 293 in 0af2c2b
How did you test this change?
Test passes, I also tested it by hacking the solution in vites output.