Entering edit mode
10.9 years ago
biostar
▴
170
Hi I am a novice perl programmer. I just installed bioperl in my mac and when I tried to invoke some programs it generates this king of error. Could you guys please help me understand what is the problem here?? Thanks!!
Mac:Desktop darwin$ perl bioperl.pl
Use of uninitialized value $inFile in string at bioperl.pl line 7.
Use of uninitialized value $outFile in concatenation (.) or string at bioperl.pl line 8.
------------- EXCEPTION: Bio::Root::Exception -------------
MSG: Could not open >: No such file or directory
STACK: Error::throw
STACK: Bio::Root::Root::throw /Library/Perl/5.12/Bio/Root/Root.pm:486
STACK: Bio::Root::IO::_initialize_io /Library/Perl/5.12/Bio/Root/IO.pm:351
STACK: Bio::SeqIO::_initialize /Library/Perl/5.12/Bio/SeqIO.pm:491
STACK: Bio::SeqIO::fasta::_initialize /Library/Perl/5.12/Bio/SeqIO/fasta.pm:87
STACK: Bio::SeqIO::new /Library/Perl/5.12/Bio/SeqIO.pm:372
STACK: Bio::SeqIO::new /Library/Perl/5.12/Bio/SeqIO.pm:413
STACK: bioperl.pl:8
-----------------------------------------------------------
how is your code looks like? it seems like an IO error not related to BioPerl, feed your code to the critic - it may explain what is wrong.
There is no way to answer this without seeing the code in bioperl.pl.
That isn't an installation problem, that stack trace tells you it cannot open a file that it cannot find and compilation warnings for Infile & Outfile. The modules are being loaded properly.
Thanks Guys!! The problem was that I did not install the cpanm module using sudo -s. It was not root execution, tha's why the error....
No, this is not related to what you posted above. If this were the case you would have seen a compile-time error that said
Can't locate Bio/SeqIO.pm in @INC ...
and the script would have halted. Clearly, BioPerl is installed because it generated a stack trace. The comments above are correct, the issue is that you are trying to initialize an object with a file that can't be found; that's what the Perl warnings tell you and the BioPerl stack trace below points to the same issue.