[Biopython-dev] run_tests.py rewrite
Peter
biopython at maubp.freeserve.co.uk
Fri Feb 13 15:48:33 UTC 2009
On Wed, Feb 4, 2009 at 1:14 PM, Peter <biopython at maubp.freeserve.co.uk> wrote:
> It look a little while to show up in CVS for me, but I've got it now.
> That seems to solve the problem neatly - and you've even managed
> to capture the stack trace elegantly, something I hadn't worked out how to do.
>
> Nice :)
Unfortunately, the traceback.format_exc() function you used to capture
the stack trace for print out is Python 2.4+ only[1]. This means if
one of the print-and-compare tests fails with an exception on Python
2.3, then run_tests.py will fall over. I've checked in a simple fix
to use the exception text instead - I'm sure something more useful
could be done for Python 2.3, but we'll be dropping support for this
fairly soon anyway.
This was failing for me on a "known failure", test_Clustalw_tool.py on
Windows Python 2.3, where some filenames with spaces just won't work
without the subprocess module (Python 2.4+ only). I don't think this
can be avoided, so I've updated test_Clustalw_tool.py to skip this bit
in future.
Peter
[1] See http://docs.python.org/library/traceback.html
More information about the Biopython-dev
mailing list