[Biopython-dev] jython/testing

Tiago Antão tiagoantao at gmail.com
Tue Aug 14 20:39:12 UTC 2012


Hi,

I have been trying to use biopython with jython 2.7 alpha 2. Here
follows a report.


There are still a few problems (with SeqIO only):
test_SeqIO ... ERROR
test_SeqIO_QualityIO ... FAIL
test_SeqIO_index ... FAIL

The errors are something like (all the same kind of stuff really):

SeqIO
======================================================================
ERROR: test_SeqIO
----------------------------------------------------------------------
Traceback (most recent call last):
  File "run_tests.py", line 341, in runTest
    suite = unittest.TestLoader().loadTestsFromName(name)
  File "/home/tr353/local/jython/Lib/unittest/loader.py", line 91, in
loadTestsFromName
    module = __import__('.'.join(parts_copy))
  File "/home/tr353/local/jython/Lib/unittest/loader.py", line 91, in
loadTestsFromName
    module = __import__('.'.join(parts_copy))
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO.py", line 627, in <module>
    check_simple_write_read(records)
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO.py", line 352, in
check_simple_write_read
    records2 = list(SeqIO.parse(handle=handle, format=format))
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO.py", line 352, in
check_simple_write_read
    records2 = list(SeqIO.parse(handle=handle, format=format))
  File "/home/tr353/tmp/biopython/Bio/SeqIO/__init__.py", line 537, in parse
    for r in i:
  File "/home/tr353/tmp/biopython/Bio/SeqIO/SffIO.py", line 828, in SffIterator
    header_length, index_offset, index_length, number_of_reads, \
  File "/home/tr353/tmp/biopython/Bio/SeqIO/SffIO.py", line 285, in
_sff_file_header
    magic_number, ver0, ver1, ver2, ver3, index_offset, index_length, \
error: unpack str size does not match format


SeqIO_QualityIO
======================================================================
ERROR: test_E3MFGYR02 (test_SeqIO_QualityIO.TestWriteRead)
Write and read back E3MFGYR02_random_10_reads.sff
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO_QualityIO.py", line
551, in test_E3MFGYR02
    self.check(os.path.join("Roche", "E3MFGYR02_random_10_reads.sff"), "sff",
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO_QualityIO.py", line
477, in check
    write_read(filename, format, f)
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO_QualityIO.py", line
52, in write_read
    records2 = list(SeqIO.parse(handle,out_format))
  File "/home/tr353/tmp/biopython/Bio/SeqIO/__init__.py", line 537, in parse
    for r in i:
  File "/home/tr353/tmp/biopython/Bio/SeqIO/SffIO.py", line 828, in SffIterator
    header_length, index_offset, index_length, number_of_reads, \
  File "/home/tr353/tmp/biopython/Bio/SeqIO/SffIO.py", line 285, in
_sff_file_header
    magic_number, ver0, ver1, ver2, ver3, index_offset, index_length, \
error: unpack str size does not match format

SeqIO.index
======================================================================
ERROR: test_sff_Roche_greek_sff_get_raw (test_SeqIO_index.IndexDictTests)
Index sff file Roche/greek.sff get_raw
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO_index.py", line
430, in <lambda>
    f = lambda x : x.get_raw_check(fn, fmt, alpha, c)
  File "/home/tr353/tmp/biopython/Tests/test_SeqIO_index.py", line
301, in get_raw_check
    rec2 = SeqIO.SffIO._sff_read_seq_record(handle,
  File "/home/tr353/tmp/biopython/Bio/SeqIO/SffIO.py", line 561, in
_sff_read_seq_record
    read_header_length, name_length, seq_len, clip_qual_left, \
error: unpack str size does not match format


I suppose this is because of issues with the alpha version of jython 2.7.

Tiago
PS - I do not have all external dependencies installed on my machine,
so a few modules are untested.

-- 
"Liberty for wolves is death to the lambs" - Isaiah Berlin



More information about the Biopython-dev mailing list