[Bioperl-l] RemoteBlast - Can't call method "query_name" on an undefined value

Paulo Almeida palmeida at igc.gulbenkian.pt
Wed Sep 14 09:36:47 EDT 2005


Hi,

Remote blasts have been giving me this error:

Can't call method "query_name" on an undefined value at testblast.pl line 43,
<GEN4> line 29

The ID of the BLAST search worked on the web (Retrieve results by ID on
 NCBI).

This is the result of running the debugger on the attached testblast.pl
 script with the attached amino.fa file (the script follows the synopsis
 closely):

------------

  DB<3> n
main::(testblast.pl:32):              foreach my $rid ( @rids ) {
  DB<3> x $rid
0  undef
  DB<4> n
main::(testblast.pl:33):                my $rc =
$factory->retrieve_blast($rid);
  DB<4> x $rid
0  '1126626136-15184-184931694060.BLASTQ3'
  DB<5> n
main::(testblast.pl:34):                if( !ref($rc) ) {
  DB<5> x $rc
0  Bio::SearchIO::blast=HASH(0x8df4484)
   '_file' => '/tmp/5A3aAj4SvD'
   '_filehandle' => GLOB(0x8d3b814)
      -> *Symbol::GEN4
            FileHandle({*Symbol::GEN4}) => fileno(8)
   '_flush_on_write' => 1
   '_handler' =>
Bio::SearchIO::IteratedSearchResultEventBuilder=HASH(0x8f23db0)
      '_factories' => HASH(0x8f2eb60)
         'hit' => Bio::Factory::ObjectFactory=HASH(0x8ee9754)
            '_loaded_types' => HASH(0x8f2ebe4)
               'Bio::Search::Hit::BlastHit' => 1
            '_root_verbose' => 0
            'interface' => 'Bio::Search::Hit::HitI'
            'type' => 'Bio::Search::Hit::BlastHit'
         'hsp' => Bio::Factory::ObjectFactory=HASH(0x8ee96f4)
            '_loaded_types' => HASH(0x8f2ebf0)
               'Bio::Search::HSP::GenericHSP' => 1
            '_root_verbose' => 0
            'interface' => 'Bio::Search::HSP::HSPI'
            'type' => 'Bio::Search::HSP::GenericHSP'
         'iteration' => Bio::Factory::ObjectFactory=HASH(0x8ee9694)
            '_loaded_types' => HASH(0x8f2eb6c)
               'Bio::Search::Iteration::GenericIteration' => 1
            '_root_verbose' => 0
            'interface' => 'Bio::Search::Iteration::IterationI'
            'type' => 'Bio::Search::Iteration::GenericIteration'
         'result' => Bio::Factory::ObjectFactory=HASH(0x8f1c07c)
            '_loaded_types' => HASH(0x8efae84)
               'Bio::Search::Result::BlastResult' => 1
            '_root_verbose' => 0
            'interface' => 'Bio::Search::Result::ResultI'
            'type' => 'Bio::Search::Result::BlastResult'
      '_inclusion_threshold' => 0.001
      '_root_verbose' => 0
   '_handler_cache' =>
Bio::SearchIO::IteratedSearchResultEventBuilder=HASH(0x8f23db0)
      -> REUSED_ADDRESS
   '_notfirsttime' => 0
   '_reporttype' => ''
   '_root_cleanup_methods' => ARRAY(0x8d3b7e4)
      0  CODE(0x845bb8c)
         -> &Bio::Root::IO::_io_cleanup
in /usr/share/perl5/Bio/Root/IO.pm:544-570
      1  CODE(0x845bb8c)
         -> REUSED_ADDRESS
   '_root_verbose' => 0
  DB<6> n
main::(testblast.pl:41):                  my $result = $rc->next_result();
  DB<6> n
main::(testblast.pl:43):                  my $filename =
$result->query_name()."\.out";
  DB<6> x $rc->next_result()
0  undef
  DB<7> n
Can't call method "query_name" on an undefined value at testblast.pl line 43,
<GEN4> line 29.
Debugged program terminated.  Use q to quit or R to restart,

---------------------

What could be going on here?

-- 
Paulo Almeida
Tel: +351 21 4464635, Fax: +351 21 4407970
Instituto Gulbenkian de Ciência
Rua da Quinta Grande, 6
P-2780-156 Oeiras
Portugal
http://www.igc.gulbenkian.pt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testblast.pl
Type: application/x-perl
Size: 1793 bytes
Desc: not available
Url : http://portal.open-bio.org/pipermail/bioperl-l/attachments/20050914/86456160/testblast.bin
-------------- next part --------------
>gi|44039|emb|CAA43547.1| Lys-aminopeptidase [Lactococcus lactis subsp. cremoris]
MAVKRLIETFVPENYKIFLDIDRKTKKIKGQVAITGEAKDTVVAFHAKGLHFNKVRAFSVDTNFIENEED
EEIVVKIGETGRVTVSFEYEAELTDNMMGIYPSYYEVNGEKKMLIGTQFESHFARQAFPSIDEPEAKATF
DLSVKFDEEEGDIIVSNMPELLNINGIHVFERTVKMSSYLLAFVFGELQYKKGKTKSGVEVGAFATKAHS
QAALDFPLDIAIRSIEFYEDYYQTPYPLPHSWHIALPDFSSGAMENWGCITYREVCMLVDPENATIQSKQ
YVATVIAHELAHQWFGDLVTMQWWDDLWLNESFANNMEYVCMDALEPSWNVWESFSISEANMALNRDATD
GVQSVHVEVTHPDEIGTLFDPAIVYAKGSRLMVMLRKWLGDEDFAAGLALYFKRHQYGNTVGDNLWDALA
EVSGKDVAAFMHSWVNQPGYPVVTAEVVDDTLILSQKQFFVGEGVDKGRLWNVPLNTNWTGLPDLLSSEK
VEIPGFAALKTKNNGKALFLNDANMAHYIIDYKGALLTDLLSEVESLENVTKFQILQDRKLLAKAGVISY
ADVVNILPSFTNEESYLVNTGLSQLISELELFVDEDSETEKAFQSLVGKLFAKNYARLGWDKVAGESAGD
ESLRGIVLSKTLYSENADAKTKASQIFATHKENLASIPADIRPIVLNNEIKTTNSAELVKTYRETYIKTS
LQEFKRELEGAVALIKDEKVIAELLESFKNADIVKPQDIAFSWFYLLRNDFSQDAAWAWEKANWASLEEK
LGGDMSYDKFVIYPGNTFKTADKLAEYKAFFEPKLENQGLKRSIEMAIKQITARVALIDSQKAAVDKAIT
DIAEKL


More information about the Bioperl-l mailing list