[Biopython-dev] [Bug 2711] GenomeDiagram.py: write() and write_to_string() are inefficient and don't check inputs

bugzilla-daemon at portal.open-bio.org bugzilla-daemon at portal.open-bio.org
Tue Jan 6 00:18:06 UTC 2009


------- Comment #21 from biopython-bugzilla at maubp.freeserve.co.uk  2009-01-05 19:18 EST -------
(In reply to comment #17)
> I do not consider this bug completely fixed for multiple reasons of which my
> patch addressed some of these prior to the creation of the _write function. I
> do like where _write is heading as it is making cleaner and more
> understandable code.

I decided that since ReportLab used a cStringIO or StringIO handle internally
to implement its writeToString method, we might as well do the same as it
allows a great simplification to the GenomeDiagram write and write_to_string
methods (and we can get rid of _write too).

See revision 1.14 of Bio/Graphics/GenomeDiagram/Diagram.py

I hope you'll agree that this is a further improvement (even if the dictionary
approach is still used internally).

My plan (see Bug 2718) is to move this code into a shared private function for
all of the Bio.Graphics modules to use.

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