[Biopython] Biopython 1.54b test failures

Christoph Gohlke cgohlke at uci.edu
Fri Apr 2 23:05:25 UTC 2010


Hello,

I get two test failures (see below) when running 'setup.py test' for 
biopython 1.54b on win-amd64-py2.6 (built with msvc9). These are related 
to line ending style. Maybe it would be a good idea to use Python's 
universal newline support (available since 2.3) when opening text files 
for iteration over lines. All tests pass after the following changes:

BIO/SCOP/Raf.py

line 104:
         f = open(self.filename, 'rU')

line 121:
         f = open(self.filename, 'rU')

BIO/SCOP/Cla.py

line 103:
         f = open(self.filename, 'rU')

line 123:
         f = open(self.filename, 'rU')

line 72 (inconsistent indentation):
             h.append("=".join(map(str,ht)))


-- Christoph



======================================================================
ERROR: Test CLA file indexing
----------------------------------------------------------------------
Traceback (most recent call last):
   File "test_SCOP_Cla.py", line 74, in testIndex
     rec = index['d1hbia_']
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Cla.py", 
line 127,
  in __getitem__
     record = Record(line)
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Cla.py", 
line 45,
in __init__
     self._process(line)
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Cla.py", 
line 51,
in _process
     raise ValueError("I don't understand the format of %s" % line)
ValueError: I don't understand the format of 5

======================================================================
ERROR: testSeqMapIndex (test_SCOP_Raf.RafTests)
----------------------------------------------------------------------
Traceback (most recent call last):
   File "test_SCOP_Raf.py", line 68, in testSeqMapIndex
     r = index.getSeqMap("103m")
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Raf.py", 
line 152,
  in getSeqMap
     sm = self[id]
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Raf.py", 
line 125,
  in __getitem__
     record = SeqMap(line)
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Raf.py", 
line 196,
  in __init__
     self._process(line)
   File 
"D:\Dev\Compile\Biopython\biopython-1.54b\build\lib.win-amd64-2.6\Bio\SCOP\Raf.py", 
line 216,
  in _process
     raise ValueError("Incompatible RAF version: "+self.version)
ValueError: Incompatible RAF version: .01

----------------------------------------------------------------------
Ran 143 tests in 98.871 seconds

FAILED (failures = 2)



More information about the Biopython mailing list