I am getting the following error in windows
while running spookyjs
but code is working in linux
.
events.js:85
throw er; // Unhandled 'error' event
^
Error: spawn casperjs ENOENT
at exports._errnoException (util.js:746:11
at Process.ChildProcess._handle.onexit (ch
at child_process.js:1137:20
at process._tickCallback (node.js:355:11)
I have installed all the dependencies and added the PATH
varaiables
npm install -g casperjs
In the command prompt casperjs
is working
Installed npm as global using
npm install -g npm
Uninstalled 0.12
and downgraded to 0.10
.
Added System variable C:\Windows\System32;
.
Any idea or suggestion will be grateful
spawn
is trying to execute the casperjs
command, make sure you can execute it from your cmd.exe
console. If this is not executing locate the casperjs
binary and make sure it's added to the PATH
Any update? I have the same issue.
Both phantomjs & casperjs are in the PATH and work from cmd.exe. Tried to install it globally too...
I'm running out of options!
EDIT: OK I didn't test this but it makes sense. Apparently spawn can't handle .bat and .cmd files, hence why it does work from cmd.exe but not from spawn when PhantomJS and CasperJS are installed via npm. Installing them manually should work because you'll have phantomjs.exe and casperjs.exe. Gonna try it tonight.
EDIT2: Yep. Works. Install them manually (and put the new path in the PATH variable) and you're good to go.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With