my $task = POE::Wheel::Run->new( Program => sub { &{$this_code} }, ProgramArgs => \@program_args, StdoutFilter => POE::Filter::Reference->new(), StdinEvent => 'task_stdin', # Flushed all data to the child's STDIN. StdoutEvent => 'task_result', # Received data from the child's STDOUT. StderrEvent => 'task_debug', # Received data from the child's STDERR. # ErrorEvent => 'task_error', # An I/O error occurred. CloseEvent => 'task_close', # Child closed all output handles. ); $heap->{task}->{ $task->ID } = $task;