title: ReportLab: Flowable too large on page 1 in frame 'normal' of template 'First'
body: <p>I build PDF using ReportLab. My program has a <code>MyDocTemplate(SimpleDocTemplate)</code> class with two methods: <code>beforePage(self)</code> and <code>afterPage(self)</code> which add header and footer (as PNG image) on every page. There is also a <code>MyDocStyle</code> class which describe <code>ParagraphStyle</code>.</p>
  
  <p>Main method looks like this:</p>
  
  <pre><code>TITLE = Paragraph(Title, MyDocStyle.h1)
  TO = Paragraph(To, MyDocStyle.h2)
  FROM = Paragraph(From, MyDocStyle.h2)
  SUBJECT = Paragraph(Subject, MyDocStyle.h2)
  LONG_PARAGRAPH = Paragraph(Text, MyDocStyle.h3)
  ...
  
  Elements = [TITLE, TO, FROM, SUBJECT, LONG_PARAGRAPH, ...]
  doc = MyDocTemplete('output.pdf', pagesize=A4, 
                       leftMargin=2*cm, rightMargin=2*cm,
                       topMargin=4*cm, bottomMargin=4*cm)
  doc.build(Elements)
  </code></pre>
  
  <p>Data comes from CSV files and GUI. From time to time (depends on data length) I receive an error:</p>
  
  <pre><code>Flowable &lt;Spacer at 0x2631120 frame=normal&gt;...(1 x 5.66929133858) too large
  on page 1 in frame 'normal'(469.88976378 x 603.118110236) of template 'First'
  </code></pre>
  
  <p>This exception stop my program. For short Paragraphs I set in <code>MyDocStyle</code> class <code>h2.keepWithNext = 1</code> however it's not perfect solution. ReportLab split correctly long paragraph if end of paragraph does not "coincide" with end of page (text area).</p>
  
  <p>How can I deal with it?</p>