How to get logs of phantomjs?


Hi, sorry but i did not found an answer so I try to find it here:

I use phantomjs in windows commandline like this:

phantomjs actions.js

In the file actions.js my javascript actions are implemented.

My problem:
Console.log - outputs are only made, if in the file actions.js has no bug. If there is a bug the phantomjs process hangs and as there are no trace messages in console it is not possible for me to find out, whtats the problem in the actions.js.

Do you know how can I see logs in this case for further bug analysis?


Default log directory (under Linux) is /var/log/ You should look there…
To debug PJS, run it with option --debug It will print many useful things, so its best to pipe it to some file, than use combination of cat and grep commands to filter-out desired pattern…