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

addons-napi/test_uv_loop test is fragile (it may freeze) #20169

Closed
iamstolis opened this issue Apr 20, 2018 · 3 comments
Closed

addons-napi/test_uv_loop test is fragile (it may freeze) #20169

iamstolis opened this issue Apr 20, 2018 · 3 comments
Labels
node-api Issues and PRs related to the Node-API. test Issues and PRs related to the tests.

Comments

@iamstolis
Copy link

  • Version: v8.11.1
  • Platform: Linux stola-ThinkPad 3.16.0-38-generic io.js on The Changelog! #52~14.04.1-Ubuntu SMP Fri May 8 09:43:57 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
  • Subsystem: addons-napi

addons-napi/test_uv_loop test is fragile. It does not protect itself from getting stuck in an unlimited wait of uv__io_poll(). In fact, the test freezes if I comment out SetupGarbageCollectionTracking(env); at the end of node::performance::Init(). In other words, the test finishes just because an unlimited wait of uv__io_poll() is terminated by an event coming from a garbage collection. When these events are disabled then the test stays in uv__io_poll() forever. The test should be updated not to depend on such fragile external events, i.e., it should use an idle handle, for example. In fact, I've just realized that the test is fixed in master branch for 3 months already. Is there any reason why the test is not fixed in v8.x branch as well?

@mhdawson
Copy link
Member

There is a PR to backport the N-API changes to 8.x here: #19265. Is the change covered there? If so then it should be merged relatively soon.

@iamstolis
Copy link
Author

Yes, thanks, I see the needed change there (the diff in test/addons-napi/test_uv_loop/test_uv_loop.cc).

@richardlau
Copy link
Member

This was fixed in 8.11.2 by e15f577.

@richardlau richardlau added test Issues and PRs related to the tests. node-api Issues and PRs related to the Node-API. v8.x labels Nov 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
node-api Issues and PRs related to the Node-API. test Issues and PRs related to the tests.
Projects
None yet
Development

No branches or pull requests

3 participants