Unitech / pm2

Node.js Production Process Manager with a built-in Load Balancer.
https://pm2.keymetrics.io/docs/usage/quick-start/
Other
41.56k stars 2.63k forks source link

Interface tests hang #2246

Closed wilfredjonathanjames closed 7 years ago

wilfredjonathanjames commented 8 years ago

Expected behaviour

I should be able to run tests, and get an informative error if necessary.

Note that this is checked out from master.

Actual behaviour

Tests hanging at interface testing

#
# Interface testing
#
mocha ./test/interface/interactor.connect.mocha.js

  Interactor testing
2016-06-28 10:53:41: [PM2][WORKER] Started with refreshing interval: 30000
[Keymetrics.io] Using (Public key: osef) (Private key: osef)
Got new connection on mock server
2016-06-28 10:53:43: Starting execution sequence in -fork mode- for app name:custom-action id:0
2016-06-28 10:53:43: App name:custom-action id:0 online
    Input command / Output data checks
      1) should send ask, receive ask:rep and identify agent

Steps to reproduce

OS         : OSX 10.11
node.js    : 5.6.0
PM2        : 1.2.0

PM2 Log output

2016-06-28 10:53:22: PUB socket closed
2016-06-28 10:53:23: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 10:53:25: Starting execution sequence in -fork mode- for app name:return-data id:0
2016-06-28 10:53:25: App name:return-data id:0 online
2016-06-28 10:53:25: Stopping app:return-data id:0
2016-06-28 10:53:25: App [return-data] with id [0] and pid [68341], exited with code [0] via signal [SIGINT]
2016-06-28 10:53:26: PM2 is being killed via kill method
2016-06-28 10:53:26: RPC socket closed
2016-06-28 10:53:26: PUB socket closed
2016-06-28 10:53:27: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 10:53:29: PM2 is being killed via kill method
2016-06-28 10:53:29: RPC socket closed
2016-06-28 10:53:29: PUB socket closed
2016-06-28 10:53:31: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 10:53:31: [[[[ PM2/God daemon launched ]]]]
2016-06-28 10:53:31: BUS system [READY] on port /Users/wilfred.godfrey/.pm2/pub.sock
2016-06-28 10:53:31: RPC interface [READY] on port /Users/wilfred.godfrey/.pm2/rpc.sock
2016-06-28 10:53:33: PM2 is being killed via kill method
2016-06-28 10:53:33: RPC socket closed
2016-06-28 10:53:33: PUB socket closed
2016-06-28 10:53:34: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 10:53:36: Starting execution sequence in -fork mode- for app name:child id:0
2016-06-28 10:53:36: App name:child id:0 online
2016-06-28 10:53:36: Stopping app:child id:0
2016-06-28 10:53:36: App [child] with id [0] and pid [68379], exited with code [0] via signal [SIGINT]
2016-06-28 10:53:36: Proc is not defined anymore or is being killed
2016-06-28 10:53:36: Starting execution sequence in -fork mode- for app name:child id:0
2016-06-28 10:53:36: App name:child id:0 online
2016-06-28 10:53:36: Stopping app:child id:0
2016-06-28 10:53:36: App [child] with id [0] and pid [68397], exited with code [0] via signal [SIGINT]
2016-06-28 10:53:36: Proc is not defined anymore or is being killed
2016-06-28 10:53:36: Starting execution sequence in -fork mode- for app name:child id:0
2016-06-28 10:53:36: App name:child id:0 online
2016-06-28 10:53:36: Stopping app:child id:0
2016-06-28 10:53:36: App [child] with id [0] and pid [68416], exited with code [0] via signal [SIGINT]
2016-06-28 10:53:36: Proc is not defined anymore or is being killed
2016-06-28 10:53:36: PM2 is being killed via kill method
2016-06-28 10:53:36: RPC socket closed
2016-06-28 10:53:36: PUB socket closed
2016-06-28 10:53:38: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 10:53:38: [[[[ PM2/God daemon launched ]]]]
2016-06-28 10:53:38: BUS system [READY] on port /Users/wilfred.godfrey/.pm2/pub.sock
2016-06-28 10:53:38: RPC interface [READY] on port /Users/wilfred.godfrey/.pm2/rpc.sock
2016-06-28 10:53:40: PM2 is being killed via kill method
2016-06-28 10:53:40: RPC socket closed
2016-06-28 10:53:40: PUB socket closed
2016-06-28 11:04:37: [PM2][WORKER] Started with refreshing interval: 30000
2016-06-28 11:04:37: [[[[ PM2/God daemon launched ]]]]
2016-06-28 11:04:37: BUS system [READY] on port /Users/wilfred.godfrey/.pm2/pub.sock
2016-06-28 11:04:37: RPC interface [READY] on port /Users/wilfred.godfrey/.pm2/rpc.sock
vmarchaud commented 7 years ago

Some tests can sometime fail without good reason, just retry. If they persist, it should come from the source code but remember if our own CI hasn't problem, it must come from your system. Btw you should try with pm2 v2