Skip Menu |
 

This queue is for tickets about the POE CPAN distribution.

Report information
The Basics
Id: 33684
Status: rejected
Priority: 0/
Queue: POE

People
Owner: Nobody in particular
Requestors: ralph.lu [...] bluecoat.com
Cc:
AdminCc:

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



Subject: POE::Wheel::ReadWrite I/O non-bloking error
Date: Thu, 28 Feb 2008 17:00:13 -0800
To: <bug-POE [...] rt.cpan.org>
From: "Lu, Ralph" <ralph.lu [...] bluecoat.com>
Download q.pl
text/x-perl 1.2k

Message body is not shown because sender requested not to inline it.

Download err
application/octet-stream 2.4k

Message body not shown because it is not plain text.

Download (untitled) / with headers
text/plain 365b
Hi, I am trying to create a script which handles non-blocking user input. It asked me to send the error message when I tried to run it. I attached the error log and the perl script for your reference. It took me a couple of hours trying to figure out what happened, but I still couldn't get anything. Thank your very much for your comments, Ralph
Download (untitled) / with headers
text/plain 255b
Perl's select() only supports sockets. You cannot use it with STDIN/STDOUT. If you require user input on Windows, maybe you can use POE::Component::Server::TCP and Windows' TELNET.EXE. Alternatively, you can develop a graphical interface with POE & Tk.
Subject: RE: [rt.cpan.org #33684] POE::Wheel::ReadWrite I/O non-bloking error
Date: Mon, 24 Mar 2008 07:15:27 -0700
To: <bug-POE [...] rt.cpan.org>
From: "Lu, Ralph" <ralph.lu [...] bluecoat.com>
Download (untitled) / with headers
text/plain 687b
Hi, Thank you. But this works under Cygwin. I believe it will work under UNIX/LINUX too. Looks to me this PoCO doesn't work under Windows platform. Thanks, Ralph Show quoted text
-----Original Message----- From: RCAPUTO via RT [mailto:bug-POE@rt.cpan.org] Sent: Saturday, March 22, 2008 6:11 PM To: Lu, Ralph Subject: [rt.cpan.org #33684] POE::Wheel::ReadWrite I/O non-bloking error <URL: http://rt.cpan.org/Ticket/Display.html?id=33684 > Perl's select() only supports sockets. You cannot use it with STDIN/STDOUT. If you require user input on Windows, maybe you can use POE::Component::Server::TCP and Windows' TELNET.EXE. Alternatively, you can develop a graphical interface with POE & Tk.
Download (untitled) / with headers
text/plain 902b
The following is a known problem with ActiveState, and I believe the vanilla/strawberry/chocolate versions of Perl on Windows: $heap->{readwrite} = POE::Wheel::ReadWrite->new ( InputHandle => \*STDIN, OutputHandle => \*STDOUT, Driver => POE::Driver::SysRW->new(), Filter => POE::Filter::Line->new(), InputEvent => User_Input, ErrorEvent => Input_Fail, FlushedEvent => Input_Shutdown ); print "child_event end\n"; The Perl built-in select() call is based on the winsock select() which only works on sockets. Therefore select() in perl cannot be used on console handles (STDIN & STDOUT) in ActiveState, vanilla, strawberry or chocolate Perl on Windows. Cygwin implements its own select() which is not based on WinSock. As a result, select() works for console filehandles under Cygwin Perl.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.