[Biopython-dev] [Bug 2803] Insure Alignment objects are passed to AlignIO.write()

bugzilla-daemon at portal.open-bio.org bugzilla-daemon at portal.open-bio.org
Wed Apr 1 15:55:26 UTC 2009


http://bugzilla.open-bio.org/show_bug.cgi?id=2803


biopython-bugzilla at maubp.freeserve.co.uk changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED




------- Comment #4 from biopython-bugzilla at maubp.freeserve.co.uk  2009-04-01 11:55 EST -------
(In reply to comment #3)
> > Anyway, I'll take a look at this.  I think we need to just check the case
> > where Bio.AlignIO.write uses Bio.SeqIO.write internally...

That turned out to be the case, fixed in CVS.  See Bio/AlignIO/__init__.py
revision 1.22 and Tests/test_AlignIO.py 1.19

> Yes, I see. I had originally intended to check the type while looping through
> the alignments before calling SeqIO.write, but thought better of it because
> some alignments may get written before a error occurs, whereas it seems best
> that either all or none at all get written from the call to AlignIO.write. 

You are right, if we are given a list/iterator containing some real Alignments
but also some non-Alignments we have a problem.  We can't pre-check all the
entries before writing without converting to a list (and this ruins the memory
benefits).  We just catching the erroneous input when we reach it, even though
it may happen half way through writing to the file.

Marking as fixed.


-- 
Configure bugmail: http://bugzilla.open-bio.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the Biopython-dev mailing list