-
Notifications
You must be signed in to change notification settings - Fork 168
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
stack overflow running tests in node 0.10 #73
Comments
I know mocha had similar issues, see mochajs/mocha#777 -- so this might be a bug in the test runner, not in html5 itself. |
Note that html5 is using node-tap, not mocha, as its test runner. I expect it is a similar issue where nextTick should be replaced with setImmediate, though. I find stack overflows really painful to troubleshoot in the current Node releases because you get no context (call stack) at all. This is actually due to V8, not Node, and V8 fixed this a while ago, and I've been eagerly awaiting it showing up in Node (it showed up in V8 3.15, Node 0.10 is using V8 3.14, Node 0.11 unstable cycle releases are now at V8 3.16.17) so I built node from current 0.11 bleeding edge source the other day to try this out. For this issue I get this stack trace:
which is something, but not enough to go on. Invoking node with --throw-deprecation turns out to be more helpful, as it gives us a call stack from the first offense (when process.nextTick finds recursive invocations), not the last offense (when it's happened so many times the stack overflows). That gives us
Still not enough frames to see all the way from one nextTick call to the recursive one, but it does point the finger generally in tap's direction. Without taking the time to deeply understand the tap code, I found two uses of process.nextTick in its codebase proper, changed both to setImmediate, and reran the However the tests run much more slowly, and basically tie up the CPU. So this doesn't seem like a good idea. |
Oh, excellent! Thank you! |
This should be mostly better now -- can you try? |
I tried running
tree-construction-test.js
in node 0.10, and test casedata/tree-construction/tests25.dat-19
failed first with a few hundred repeats ofand then finally
The text was updated successfully, but these errors were encountered: