Skip Menu |

This queue is for tickets about the POE-Component-Client-Ping CPAN distribution.

Report information
The Basics
Id: 19462
Status: resolved
Priority: 0/
Queue: POE-Component-Client-Ping

People
Owner: Nobody in particular
Requestors: chris [...] bingosnet.co.uk
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 1.10
Fixed in: (no value)



Subject: Passing arbitrary data appears broken
The passing of arbitary data appears to not be working as advertised: Test Script: #!/usr/bin/perl use strict; use warnings; use POE qw(Component::Client::Ping); use Data::Dumper; $|=1; my $address = $ARGV[0]; die unless $address; POE::Component::Client::Ping->spawn( Alias => 'pinger', OneReply => 1 ); POE::Session->create( package_states => [ 'main' => [ qw(_start pong) ], ], options => { trace => 0 }, ); $poe_kernel->run(); exit 0; sub _start { my ($kernel,$heap) = @_[KERNEL,HEAP]; $kernel->post( 'pinger', 'ping', [ 'pong', 'foo' ], $address ); undef; } sub pong { my ($heap, $request, $response) = @_[HEAP, ARG0, ARG1]; print STDOUT Dumper( $request ); print STDOUT Dumper( $response ); undef; } __END__ Results: 1.04 $ perl testcase.pl 100.0.0.12 $VAR1 = [ '100.0.0.12', 1, '1148478604.42889', 'foo' ]; $VAR1 = [ '100.0.0.12', '0.000467061996459961', '1148478604.42947' ]; 1.11 $ perl testcase.pl 100.0.0.12 $VAR1 = [ '100.0.0.12', 1, '1148478667.73387' ]; $VAR1 = [ '100.0.0.12', '0.000382900238037109', '1148478667.73433' ]; Many thanks in advance, BinGOs
Looks can be deceiving, but they aren't in this case. I've added your test case, fixed the bug, and am currently sending a new version to PAUSE. Thanks!