[Bioperl-l] Filehandle interface in Bio::AlignIO: broken in 1.4?

Dave NO SPAM Ardell myfirstname-DOT-mylastname at icm.uu.se
Sat Jan 31 09:14:35 EST 2004


Hi,

I searched for this in docs and the mailing list but didn't find  
anything. Also
looked quickly in bugzilla and the Changelist with no result.
So sorry if I am rehashing something known.

Was surprised after installing 1.4 that filehandle functionality  
documented
as part of the interface in AlignIO seems broken. That is to say,

1: $stream = Bio::AlignIO->newFh('-format' => "$opt_i"); # read from  
standard input
2: while ( my $aln = <$stream> ) {

doesn't work anymore. It doesn't die, but the diamond operator returns
null regardless of input. During debugging,

gdb> x $stream

after line 1 above, executing with sequence input on STDIN
gives:

------ BEGIN DEBUGGER OUTPUT
0  GLOB(0xbbd178)
    -> *Symbol::GEN0
Can't locate object method "FILENO" via package "Bio::AlignIO::fasta"  
at /System/Library/Perl/5.8.1/dumpvar.pl line 238.
         dumpvar::unwrap('GLOB(0xbbd178)',3,-2) called at  
/System/Library/Perl/5.8.1/dumpvar.pl line 118
         dumpvar::DumpElem('GLOB(0xbbd178)',3,-2) called at  
/System/Library/Perl/5.8.1/dumpvar.pl line 223
         dumpvar::unwrap('ARRAY(0xbbd0e8)',0,-1) called at  
/System/Library/Perl/5.8.1/dumpvar.pl line 33
         main::dumpValue('ARRAY(0xbbd0e8)',-1) called at  
/System/Library/Perl/5.8.1/perl5db.pl line 5270
         DB::dumpit('GLOB(0x143988)','ARRAY(0xbbd0e8)') called at  
/System/Library/Perl/5.8.1/perl5db.pl line 647
         DB::eval called at /System/Library/Perl/5.8.1/perl5db.pl line  
3314
         DB::DB called at /Users/dave/Data/mybin/pi line 44

----- END DEBUGGER OUTPUT -----

I see from recent scripts, for instance, bp_sreformat.pl, and from  
documentation
that stdin/stdout functionality can be had through AlignIO::new

But for my quickfix, I reinstalled bioperl 1.2.3

Maybe the change is intentional.
Although I guess I would miss the filehandle interface,
I could get over it =)
  Maybe the change should be documented though.

Apologies if it is and I missed it.

Dave


--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+-- 
+--
David Ardell, Asst. Professor.  			tel   : 46 (0) 18 471 6694
Linnaeus Centre for Bioinformatics		fax  : 46 (0) 18 471 6698
Uppsala University Biomedical Center      http://www.lcb.uu.se/~dave
Husargatan 3, Box 598,				
SE 751 24 Uppsala SWEDEN.



More information about the Bioperl-l mailing list