[Biopython-dev] Python 3 porting

Peter biopython at maubp.freeserve.co.uk
Sun Jul 11 09:47:09 UTC 2010


2010/7/11 Tiago Antão <tiagoantao at gmail.com>:
> 2010/7/11 Eric Talevich <eric.talevich at gmail.com>:
>> NumPy is keeping notes on what they did to make their code work on Python 3.
>> Have you seen this?
>> http://projects.scipy.org/numpy/browser/trunk/doc/Py3K.txt
>>
>> They use 2to3 in setup.py, too.
>
> I did not know about that link, many thanks.
>
> But their use of 2to3 on setup.py seems very good (BTW, the setup that
> I've sent you in a previous message does that and is inspired in
> numpy).
>
> Inspired on numpy, here is a suggestion on how things might work in a
> biopython version that is both 2 and 3 compatible:

Hi all,

While at EuroSciPy 2010 I've been chatting to Pauli Virtanen and David
Cournapeau about how NumPy etc are doing things - they have got a
working single code base written in Python 2.x which supports Python 3
via the 2to3 script, and plan to continue like this for the medium term.
For their C code, then the usual #ifdef tricks are used. See also:
http://mail.scipy.org/pipermail/numpy-discussion/2010-July/051436.html

Peter




More information about the Biopython-dev mailing list