Skip to content
This repository has been archived by the owner on Apr 22, 2023. It is now read-only.

test-debug-signal-cluster.js failing sporadically #6440

Closed
isaacs opened this issue Oct 30, 2013 · 5 comments
Closed

test-debug-signal-cluster.js failing sporadically #6440

isaacs opened this issue Oct 30, 2013 · 5 comments
Labels
Milestone

Comments

@isaacs
Copy link

isaacs commented Oct 30, 2013

Example: http://jenkins.nodejs.org/job/node-pullrequest/1471/DESTCPU=ia32,label=linux/tapTestReport/test.tap-104/

Running the test a bunch of times in a loop usually makes it fail within 10 or so iterations for me.

@bnoordhuis
Copy link
Member

For posterity, the reason it sometimes fails is that the master sends a SIGUSR1 signal before the worker has a chance to install a signal handler for it. I made it less worse in commit 4234bcc but it's still an issue.

/cc @bajtos

@bajtos
Copy link

bajtos commented Oct 31, 2013

I can add a delay of 200ms before calling process._debugProcess at line 46. Is that good enough?

@bnoordhuis
Copy link
Member

Please ignore my previous comment. That commit did fix some issues with the cluster+debugger tests but I see that this particular test waits for the workers to get online before it starts sending the signals. For that matter, I ran the test 100x on two machines and it always passes for me.

@misterdjules
Copy link

It seems that now test-debug-signal-cluster.js passes on all platforms, but fails all the time on SmartOS. Here's one instance of such a failure: http://jenkins.nodejs.org/job/nodejs-v0.12/DESTCPU=ia32,label=smartos/lastBuild/tapTestReport/simple.tap-126/. Adding it to the 0.11.15 milestone as it's one of the very few failing tests remaining.

@misterdjules misterdjules added this to the 0.11.15 milestone Jan 15, 2015
tjfontaine added a commit to tjfontaine/node that referenced this issue Jan 15, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes nodejs#6440
misterdjules pushed a commit to misterdjules/node that referenced this issue Jan 15, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes nodejs#6440

Signed-off-by: Julien Gilli <julien.gilli@joyent.com>
misterdjules pushed a commit to misterdjules/node that referenced this issue Jan 16, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes nodejs#6440

Signed-off-by: Julien Gilli <julien.gilli@joyent.com>
misterdjules pushed a commit to misterdjules/node that referenced this issue Jan 16, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes nodejs#6440
misterdjules pushed a commit to misterdjules/node that referenced this issue Jan 16, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes nodejs#6440

Signed-off-by: Julien Gilli <julien.gilli@joyent.com>
@misterdjules
Copy link

Fixed by e9df9a0 and 58fcc65, thanks @tjfontaine!

bnoordhuis pushed a commit to bnoordhuis/io.js that referenced this issue Jan 19, 2015
Previously if a worker's state machine had already transitioned into the
'listening' state when it received the message enabling the debugger,
the worker would never enable its debugger.

Change the logic to allow the 'listening' as a valid state for enabling
the debugger.

Fixes: nodejs/node-v0.x-archive#6440
Original-PR-URL: nodejs/node-v0.x-archive#9037
Signed-off-by: Julien Gilli <julien.gilli@joyent.com>

Fixes: nodejs#340
PR-URL: nodejs#501
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Bert Belder <bertbelder@gmail.com>
Reviewed-By: Rod Vagg <rod@vagg.org>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

6 participants