[reportlab-users] 2.5 tests-preinstall failures

Phil Dumont phil at solidstatescientific.com
Mon Nov 8 10:00:20 EST 2010


I've recently grabbed the version 2.5 tarball. Before installing, I'm
running 'python setup.py tests-preinstall'. I'm getting several test
failures.

I've done a little debugging of one of them -- the first one. (The rest
look like they might be similar.) I've got this far with it:

tests.test_platypus_index.IndexTestCase.test0 is handing the parser some
text with three "index" tags in it, each of which has an "item" attribute.
In one of the item attribute values, there is an ampersand character
reference ('&'). In each of the other two, there is a plain old
ampersand, all by itself, not part of an entity or character reference. It
looks as though it's expected that the plain ampersand in the tag attribute
values are ok. But the parser balks on them (specifically, when
reportlab.lib.xmllib.SlowXmlParser.parse_starttag() hands the attribute
value to translate_references()).

So, should ampersands be allowed in attribute values or not? If so, why is
the parser complaining? If not, why is there a test that tries to put them
there?

Yeah, I saw the attempt to import sgmlop. (Do the tests work with it?) And
no, sgmlop is not currently installed on my machine. I can if I have to.
But I'd like to trim my dependency tree a bit. I understand the reportlab's
home-grown parser is expected to be slower (I don't think I care, yet), but
it should work the way reportlab's tests expect it to, n'est-ce pas?

Thanks.

phil dumont
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://two.pairlist.net/pipermail/reportlab-users/attachments/20101108/12407cbf/attachment.html>


More information about the reportlab-users mailing list