-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Unable to build library using grunt. Fatal error: Protocol error (Runtime.callFunctionOn): Object reference chain is too long. #5367
Comments
Welcome! 👋 Thanks for opening your first issue here! And to ensure the community is able to respond to your issue, be sure to follow the issue template if you haven't already. |
@malviys Can you share a more complete console output? |
@limzykenneth It is very long output Grunt builds and runs test all test cases. Don't know how much code would be sufficient because it tries to run test cases and then fails. |
Basically we need to know which task failed and if it's the test, which test is causing the issue. I know it can be difficult to tell where the issue occur at first glance so if you could share a more complete output I can diagnose it better. You can put it on a gist or pastebin as those are a bit more suitable for long text than github issue comments. |
@limzykenneth here is the pastebin link https://pastebin.com/FdULWrF2 for the error details |
It seems to be a puppeteer problem. You can change your node.js version to 14.x and npm version to 6.x and you should be able to run |
I couldn't do a straightforward update to puppeteer 10.2.0 (latest version) because of a few failed unit tests that I'm not too familiar with. @outofambit Can you perhaps have a look?
|
The unit tests are now fixed by #5412 but after testing updating to 10.2.0, the same error described in the original issue still occurs. I filed an issue with puppeteer, hopefully that get some respond. In #5409 playwright was mentioned as an alternative, might be worth trying if it gives us better build stability. |
src\math\p5.Vector.js
toString documentation
p5.Vector Object : [20, 30, 0]
✓ example #1 works
✓ example #2 works
set documentation
✓ example #1 works
✓ example #2 works
copy documentation
true
✓ example #1 works
add documentation
✓ example #1 works
✓ example #2 works
Fatal error: Protocol error (Runtime.callFunctionOn): Object reference chain is too long Am still getting this error. Will I have to revert back to previous node and npm versions?
|
@DivyamAhuja Yes, that's what was mentioned in terms of the original error. Reverting to node 14 should work. We're looking into solutions for node 16. |
Good news and bad news. Good news: I found the source of this problem. Bad news: may be a bit tricky to resolve. For a more detailed explanation see the issue on puppeteer: puppeteer/puppeteer#7570. Essentially the problem occurs because there's a cyclic reference in There are a few ways that we can possibly resolve this. First way is to not have the cyclic reference in the first place (it came from |
TLDR: I manage to remove the reference to the p5 instance from p5.Vector objects and everything seems to work now. Will file a PR. For posterity: So I've looked into some potential solutions and the first is to remove cyclic reference entirely. This proves to be very difficult as not just Another potential solution is to remove the reference to the p5 instance in the |
Most appropriate sub-area of p5.js?
Details about the bug:
Unable to build library using grunt
Console error:
The text was updated successfully, but these errors were encountered: