[Biopython-dev] [Bug 3168] New: different StringIO import for Python 3

bugzilla-daemon at portal.open-bio.org bugzilla-daemon at portal.open-bio.org
Wed Jan 12 13:54:30 UTC 2011


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

           Summary: different StringIO import for Python 3
           Product: Biopython
           Version: Not Applicable
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Main Distribution
        AssignedTo: biopython-dev at biopython.org
        ReportedBy: michael.kuhn at gmail.com


Bio/File.py fails in Python 3, because StringIO.StringIO has been moved to the
io module. These changes fix this (in Bio/File.py): 

import StringIO

-->

try:
    from StringIO import StringIO
except ImportError:
    from io import StringIO



and


StringHandle = StringIO.StringIO

-->

StringHandle = StringIO



(I didn't see a proper process documented anywhere to submit patches with the
whole 2to3 conversion going on at the same time).


-- 
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