[reportlab-users] KeepTogethor Splitting Error

Andy reportlab-users@reportlab.com
Mon, 4 Oct 2004 07:46:53 -0500


Once again I ran into this problem today.  I don't know why this happens.  I 
have a list of keeptogethors, each keeptogethor has three elements in it (two 
paragraphs and a flowable that emulates an html HR.  It seems when building 
the pdf that a page runs out of space, it tries to add a keeptogethor to a 
page but fails.  Instead of pushing this to the next page, it raises a Layout 
Error.

Any thoughts as to why this would happen?

Any help would be MUCH appreciated!
Andy

Here's the traceback:
  File "/export1/Zope-2.7.0-rc2/Products/BethelNews/ENewsletterEdition.py", 
line 246, in run_publishing_operations
    self._publishToBucket(person,prefs[0], prefs[0]
['audiences'].split(','),audience_order,buckets)
  File "/export1/Zope-2.7.0-rc2/Products/BethelNews/ENewsletterEdition.py", 
line 444, in _publishToBucket
    pdf_data = str(self.generatePDF(audiences=myorder))
  File "/export1/Zope-2.7.0-rc2/Products/BethelNews/ENewsletterEdition.py", 
line 522, in generatePDF
    text = pdfb.build()
  File "/export1/Zope-2.7.0-rc2/Products/BethelNews/pdf_generator.py", line 
206, in build
    doc.build(self.elements,myFirstPage,myLaterPages)
  File 
"/usr/local/lib/python2.3/site-packages/reportlab/platypus/doctemplate.py", 
line 801, in build
    BaseDocTemplate.build(self,flowables)
  File 
"/usr/local/lib/python2.3/site-packages/reportlab/platypus/doctemplate.py", 
line 631, in build
    self.handle_flowable(flowables)
  File 
"/usr/local/lib/python2.3/site-packages/reportlab/platypus/doctemplate.py", 
line 567, in handle_flowable
    raise LayoutError("Splitting error(n==%d) on page %d in\n%s" % 
(n,self.page,f.identity(30)))