in reply to Re: POE session remains alive
in thread POE session remains alive

Ok i've found a solution,I don't really know if it's how POE was designed to run , but reading the documentation and trying to make it work I just couldn't find any other way. I am sure that there is a "official" way or something,so if someone is kind enough please show it to me.

use warnings; use strict; use Tk; use POE; POE::Session->create ( inline_states => { _start => sub { my ( $kernel, $session, $heap ) = @_[ KERNEL, SESSION, HEA +P ]; # # # _start does important stuff... # # $kernel->yield("some_loop"); }, some_loop => sub { $_[KERNEL]->delay("ev_count",10);#to keep session alive }, } ); $poe_kernel->run(); exit 0;