Bioperl: Bio::Index examples bug?

Mark Dalphin
Mon, 24 Apr 2000 12:23:20 -0700


I haven't played with the Bio::Index modules much, but they look perfect for a
task at hand.  I believe I have found a bug in the examples released with
BioPerl 0.6, however.

scripts/ - works as advertised.

scripts/ - has a problem.

Everytime I call on an index created by, it fails long
before it ever tries to access the DBM file. It seems that for "local" indexes,
it first checks its "type_and_version" which calls "_version" to check that the
versions match. So far, quite nice, however, in, it does a clever
trick of calling Bio::Index::Abstract->new() to open the DBM index file and then
having the index object re-blessed into the correct type.  The problem is that
Bio::Index::Abstract->_version() throws an error, claiming that the method must
be declared by the sub-type. Unless, I badly misunderstand what is going on
here, I think is broken.

Since I needed a Fasta Index anyway, I merely replaced
Bio::Index::Abtract->new() with Bio::Index::Fasta->new() and things worked well.

SUMMARY: It appears to me that the example,, is out of date with the
current (and apparently good) version of Bio::Index::Abstract.  I might be able
to make changes to, but the original author has done a very pretty
job of coding things so before I try and submit fixes, I'll mention the bug and
perhaps the author can find a pretty solution for fixing them.

Thanks to all the authors for a very useful set of modules!


Mark Dalphin                          email:
Mail Stop: 29-2-A                     phone: +1-805-447-4951 (work)
One Amgen Center Drive                       +1-805-375-0680 (home)
Thousand Oaks, CA 91320                 fax: +1-805-499-9955 (work)

=========== Bioperl Project Mailing List Message Footer =======
Project URL:
For info about how to (un)subscribe, where messages are archived, etc: