Spawned process exit code null

617 views
Skip to first unread message

sebastian dolber

unread,
Nov 11, 2010, 8:54:01 AM11/11/10
to nodejs
Hi,

I'm using the 'child_process' module to spawn a node process, which
sometimes is terminating with a null exit code. I've read in the docs
that this means the process didn't finish normally, still I'm not
getting any exceptions from this node child process although I'm
hooked up to the "uncaughException" event. Any ideas how I could catch
whatever's happening inside the child process?

Thanks,
Sebastian.

mscdex

unread,
Nov 11, 2010, 10:09:04 AM11/11/10
to nodejs
Is the 'signal' argument for your exit event handler null also?

Isaac Schlueter

unread,
Nov 11, 2010, 10:25:38 PM11/11/10
to nod...@googlegroups.com
The exit code should be 0 if everything went alright, or 1 if it's not

Gist the code?

--i

> --
> You received this message because you are subscribed to the Google Groups "nodejs" group.
> To post to this group, send email to nod...@googlegroups.com.
> To unsubscribe from this group, send email to nodejs+un...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/nodejs?hl=en.
>
>

Isaac Schlueter

unread,
Nov 11, 2010, 10:26:13 PM11/11/10
to nod...@googlegroups.com
On Thu, Nov 11, 2010 at 19:25, Isaac Schlueter <i...@izs.me> wrote:
> The exit code should be 0 if everything went alright, or 1 if it's not

Er, not necessarily 1, but some number other than 0.

--i

sebastian dolber

unread,
Nov 12, 2010, 8:36:34 AM11/12/10
to nodejs
The signal I'm getting is SIGKILL, but how can I trace who sent it?

Sean Braithwaite

unread,
Nov 12, 2010, 9:43:41 AM11/12/10
to nod...@googlegroups.com
strace?

sebastian dolber

unread,
Nov 12, 2010, 11:07:19 AM11/12/10
to nodejs
Yeah, it seems that strace detaches by itself after a while when I try
to attach it to a spawned process, although if I attach to the main
process I don't have the same problem. Any ideas what might be causing
this?

On Nov 12, 11:43 am, Sean Braithwaite <bra...@gmail.com> wrote:
> strace?
>
> On Fri, Nov 12, 2010 at 8:36 AM, sebastian dolber <sd.net...@gmail.com>wrote:
>
>
>
>
>
>
>
> > The signal I'm getting is SIGKILL, but how can I trace who sent it?
>
> > On Nov 11, 12:09 pm, mscdex <msc...@gmail.com> wrote:
> > > On Nov 11, 8:54 am, sebastian dolber <sd.net...@gmail.com> wrote:
>
> > > > I'm using the 'child_process' module to spawn a node process, which
> > > > sometimes is terminating with a null exit code. I've read in the docs
> > > > that this means the process didn't finish normally, still I'm not
> > > > getting any exceptions from this node child process although I'm
> > > > hooked up to the "uncaughException" event. Any ideas how I could catch
> > > > whatever's happening inside the child process?
>
> > > Is the 'signal' argument for your exit event handler null also?
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "nodejs" group.
> > To post to this group, send email to nod...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > nodejs+un...@googlegroups.com<nodejs%2Bunsu...@googlegroups.com>
> > .
Reply all
Reply to author
Forward
0 new messages