Skip Menu |

This queue is for tickets about the IO-NestedCapture CPAN distribution.

Report information
The Basics
Id: 27292
Status: open
Priority: 0/
Queue: IO-NestedCapture

People
Owner: Nobody in particular
Requestors: imacat [...] mail.imacat.idv.tw
Cc:
AdminCc:

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



Subject: Accessing Current File Handle for binmode Operations
Dear Andrew Sterling Hanenkamp, Hi. This is imacat from Taiwan. I'm trying your IO::NestedCapture, and found it is what I was looking for in the past 5 years. Thank you. However, I have a problem. I need to output and capture Perl utf8 text. utf8 text is an important feature of the Perl 5.8 localization framework. To handle this output correctly, I need to do the following: binmode $FH, ":utf8"; Also, I have to output and capture binary files. To do so I need: binmode $FH; Both requires accessing the current working file handle, but not the previous one or next one. But searching through the documetation of IO-NestedCapture-1.03 I did not see such method. Currently I'm doing this as a workaround, after peeping into the code: binmode IO::NestedCapture->instance->{"STDOUT_current"}[-1], ":utf8"; But I suppose I should not do this. Could there be a way to access the current working file handle? Thank you very much in advance.
Subject: Re: [rt.cpan.org #27292] Accessing Current File Handle for binmode Operations
Date: Fri, 25 May 2007 16:55:49 -0500
To: bug-IO-NestedCapture [...] rt.cpan.org
From: "Andrew Sterling Hanenkamp" <sterling [...] hanenkamp.com>
That's a good idea. However, I'm not actively working on or with IO::NestedCapture right now, which means that making time to work on it will be a challenge just now. I may be able to take a look at it sometime in the next couple weeks. If you can submit a patch that gives you the access you're looking for that would be of great help and would probably speed me along. If you can include a unit test for the feature as well, that would be even better. Cheers, Andrew On 5/25/07, via RT <bug-IO-NestedCapture@rt.cpan.org> wrote: Show quoted text
> > > Fri May 25 14:05:54 2007: Request 27292 was acted upon. > Transaction: Ticket created by IMACAT > Queue: IO-NestedCapture > Subject: Accessing Current File Handle for binmode Operations > Broken in: 1.03 > Severity: Wishlist > Owner: Nobody > Requestors: imacat@mail.imacat.idv.tw > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=27292 > > > > Dear Andrew Sterling Hanenkamp, > > Hi. This is imacat from Taiwan. I'm trying your IO::NestedCapture, > and found it is what I was looking for in the past 5 years. Thank you. > > However, I have a problem. I need to output and capture Perl utf8 > text. utf8 text is an important feature of the Perl 5.8 localization > framework. To handle this output correctly, I need to do the following: > > binmode $FH, ":utf8"; > > Also, I have to output and capture binary files. To do so I need: > > binmode $FH; > > Both requires accessing the current working file handle, but not the > previous one or next one. But searching through the documetation of > IO-NestedCapture-1.03 I did not see such method. Currently I'm doing > this as a workaround, after peeping into the code: > > binmode IO::NestedCapture->instance->{"STDOUT_current"}[-1], ":utf8"; > > But I suppose I should not do this. Could there be a way to access > the current working file handle? Thank you very much in advance. >
On 2007-05-25 17:56:23 Fri, sterling@hanenkamp.com wrote: Show quoted text
> That's a good idea.
Thank you. Show quoted text
> However, I'm not actively working on or with IO::NestedCapture right now, > which means that making time to work on it will be a challenge just now. I > may be able to take a look at it sometime in the next couple weeks.
That's OK. At least I still have workaround here. It's fine with me as long as you keep it in mind when you are available. Show quoted text
> If you can submit a patch that gives you the access you're looking for
that Show quoted text
> would be of great help and would probably speed me along. If you can
include Show quoted text
> a unit test for the feature as well, that would be even better.
This is also a good idea. However, I suffer from the same problem as you recently. ^^; I can look into it in a few weeks, but you may be already solving this issue then. Thank you very much again for this.