-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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
test/async-hooks/test-callback-error.js always produces core file #29286
Comments
@trevnorris I could not replicate that behavior, I checked out to |
I also could not replicate on macOS (but did not try very hard so figured it was likely I was doing something wrong, which may still end up being true....) |
I think all that we need to do is to move the test to
It does when the command line args are in the right order, i.e. with
I think it should generate a core file everywhere – the process does fail with |
FWIW, I am able to generate a core file on macOS by running the test after |
sigh Yep, forgot I had disabled core dumps entirely. Sorry for the noise. You'd never know I've been using Unix-like operating systems for 30 years. |
I could work on this with some guidance! |
@addaleax Thanks for confirming that. |
@juanarbol I can see two ways of fixing the test:
My preference is for (2).
|
@bnoordhuis I've a question, how can I append |
@juanarbol see e.g. |
@bnoordhuis Sorry, I could not patch this issue, I do not understand very good child process and async hooks, sorry again; maybe later I'll help with this kind of issues, again, thanks for the help and the examples. PS: I tried to move to abort, It didn't worked |
The test spawns a subprocess with the `--abort-on-uncaught-exception` flag and expects it to terminate with a SIGABRT signal. On systems where core dumps are enabled, that actually generates an unnecessary core dump. Set `ulimit -c 0` before spawning the subprocess. Fixes: nodejs#29286
Thank you for the fix. |
My pleasure, Trevor. :-) |
The test spawns a subprocess with the `--abort-on-uncaught-exception` flag and expects it to terminate with a SIGABRT signal. On systems where core dumps are enabled, that actually generates an unnecessary core dump. Set `ulimit -c 0` before spawning the subprocess. Fixes: #29286 PR-URL: #29478 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: David Carlier <devnexen@gmail.com>
The test spawns a subprocess with the `--abort-on-uncaught-exception` flag and expects it to terminate with a SIGABRT signal. On systems where core dumps are enabled, that actually generates an unnecessary core dump. Set `ulimit -c 0` before spawning the subprocess. Fixes: #29286 PR-URL: #29478 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: David Carlier <devnexen@gmail.com>
master
(f39ad8a),v12.x
(b4e670d) back tov12.0.0
The test
test/async-hooks/test-callback-error.js
always produces acore
file when run.Example reproduction:
Expected: Successful tests should not produce core files.
The issue comes from
case 3
above, which runs:The problem is
test_callback_abort
always has an uncaught exception. Here I've changed the test to always print the output fromcase 3
child'sstderr
:(note: the above output is from
v12.9.0
)Even though, ironically, running the test directly doesn't cause the core file:
The text was updated successfully, but these errors were encountered: