Behat/Mink — Issue #121: ZombieDriver fails with node.js 0.6.0
Author: sigmaris
Created: 2011-11-14 17:26:47+00:00
State: open

We're experiencing problems running the ZombieDriver with zombie.js. It hangs Behat when it attempts to start the node.js server.
The "stable" version of node.js that we're using is 0.6.0 from http://nodejs.org/#download
The problem seems to be caused by the fact that some part of Zombie.js is using the 'sys' module in Node, which is deprecated - as far as I can tell from http://sixarm.com/about/node_js_socket_io_fix_for_sys_and_util.html
Because of the deprecation, starting with version 0.6.0 node.js will print the following error on stderr upon running Mink's script: "The "sys" module is now called "util". It should have a similar interface"
Mink doesn't expect this appearing on stderr and thinks that zombie.js cannot be started (despite it actually starting regardless). If it sees any output from node.js on stderr at all, it throws an exception.
However, it doesn't run the pipe cleanup code and proc_close before throwing the exception in spawnZombieProcess() - this seems to cause a non-deterministic deadlock in another part of the code when the exception causes an early exit from the spawnZombieProcess() function.