[reportlab-users] Moving to Bitbucket, and development roadmap..

Marius Gedminas marius at gedmin.as
Wed Mar 20 15:54:43 EDT 2013


On Wed, Mar 20, 2013 at 03:33:09PM +0000, Andy Robinson wrote:

> On 20 March 2013 14:28, Peter Cock <p.j.a.cock at googlemail.com> wrote:

> > I would expect bytes vs unicode to be quite an issue in ReportLab, and

> > this is one of the hardest bits to deal with in a single code base targeting

> > both Python 2 and 3. The good news is if you only target Python 2.7 and

> > Python 3.3 onwards, you get to use byte and unicode literals in both (this

> > was missing in Python 3.0 to 3.2). http://www.python.org/dev/peps/pep-0414/

>

> That's one of the main reasons I want to "pull the ladder up" to 2.7.


BTW if you

from __future__ import unicode_literals

then you can use b'byte strings' and 'unicode strings', and have it work
on all Pythons starting with 2.6.


> Rather than diving straight into a port, I think it's worth going

> through all of our code that actually creates the PDF files, and

> making sure we are clear what is bytes and what is a natural-language

> (presumably unicode) string.


Ensuring you have good test coverage also helps with porting efforts.
I assume you already know about the best-of-breed solution for this,
which is https://pypi.python.org/pypi/coverage


> In any event, nothing will really start until the end of the month and

> we don't have much time to look at porting just yet. We need to get

> out a minor release first. But I am happy to take everyone's advice

> and aim for single code base, as well as pillow...


Another very useful tool is tox (and detox). It lets you run all the
tests for all supported Python versions (with detox you get to run them
in parallel). I cannot overemphasize how useful it is to have a
trivial one-command workflow to make sure your latest changes that fixed
a test on Python X haven't broken something on Python Y. IMHO detox is
the best thing to happen to Python since the invention of setuptools.

https://pypi.python.org/pypi/tox
https://pypi.python.org/pypi/detox

Marius Gedminas
--
Linux is a fast moving project, with very fast evolving components. If you're
using an older distribution, older than 4 to 6 months (and anything with
"Enterprise" in the name is by definition old), please consider going to a
newer distribution.
-- http://www.linuxpowertop.org/known.php
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 190 bytes
Desc: Digital signature
Url : <http://two.pairlist.net/pipermail/reportlab-users/attachments/20130320/9367534c/attachment.pgp>


More information about the reportlab-users mailing list