[reportlab-users] Error reporting: please say what image is failing

Andy Robinson andy at reportlab.com
Thu Mar 18 06:38:03 EDT 2010


On 18 March 2010 09:55, Robin Becker <robin at reportlab.com> wrote:

> we can if it's given as a string, and perhaps, as a file like object. Maybe

> Roberto can give some indication of where the image comes from and perhaps a

> sample.



One more idea: if people are passing in file-like objects, perhaps we
could allow an optional argument (audit_trail="foo.jpg"?) to the
image constructor or function. If an error occurs and we were not
given a filename or URL, we could add that argument to the args for
the exception.

Examples: some systems have big databases of images or pull them from
a database connection, so will be passing us file-like objects. The
programmer can then separately add an identifier.

Roberto, how should rst2pdf behave if an image is missing? Should it
fail on first error, or does it have any modes to continue-but-warn,
or put dummy image placeholders in the PDF? You probably have
issues we have had in the past with RML...

- Andy


More information about the reportlab-users mailing list