[reportlab-users] Chasing pyHnj error

Robin Becker robin at reportlab.com
Sat Nov 24 18:42:40 EST 2007


Robin Becker wrote:

> Dinu Gherman wrote:

>> Hi,

>>

>> I'm posting this here because pyHnj is part of the ReportLab distri-

>> bution and it's actually part of my attempt to write a new implemen-

>> tation of the paragraph class in Platypus.

>>

>> Maybe somebody wants to help a little bit with a confusing error I get

>> when using pyHnj on a MacBook Pro running OS 10.4.10... What I get is

>> the following really uncool Deallocation error:

> .......

> for what it's worth I get this behaviour in win32

>

> c:\usr\home\robin>python -c "import pyHnj; pyHnj.Hyphen()"

> Traceback (most recent call last):

> File "<string>", line 1, in <module>

> SystemError: error return without exception set

>

> so it's probably an error that is in the code now. It's probably an

> allocation routine error; python became much stricter recently about

> which allocation/free routines are used. We haven't been using pyHnj at

> all, but it used to work so I suspect it's the environment that changed.

> I'll take a look in the morning.


After poking around in the source I think the error happens because the
default file doesn't exist and the error isn't being handle properly. If
I cd to the rl_accel folder then run

python -c "import pyHnj; pyHnj.Hyphen('hyphen.mashed')"

the error message (and presumably the error) doesn't happen. I'll try
and fix up the code to be more discriminating and raise a proper exception.
--
Robin Becker


More information about the reportlab-users mailing list