rst2pdf / rst2pdf

Use a text editor. Make a PDF.
http://rst2pdf.github.io
MIT License
551 stars 150 forks source link

Domain with parameters too large for frame #1180

Open jack-burridge-cfh opened 1 year ago

jack-burridge-cfh commented 1 year ago

I'm trying to create a domain for a function with a large amount of parameters and it fails to build

Description of problem

I'm describing a domain with a large amount of parameters, I've got a dummy example below that causes the same issue. example.zip

When I attempt to build sphinx-build . _build -b pdf I get the error:

[ERROR] pdfbuilder.py:161 Failed to build doc
Traceback (most recent call last):
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/rst2pdf/pdfbuilder.py", line 158, in write
    docwriter.write(doctree, destination)
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/docutils/writers/__init__.py", line 80, in write
    self.translate()
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/rst2pdf/pdfbuilder.py", line 697, in translate
    createpdf.RstToPdf(
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/rst2pdf/createpdf.py", line 705, in createPdf
    pdfdoc.multiBuild(elements)
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/reportlab/platypus/doctemplate.py", line 1169, in multiBuild
    self.build(tempStory, **buildKwds)
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/reportlab/platypus/doctemplate.py", line 1082, in build
    self.handle_flowable(flowables)
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/rst2pdf/createpdf.py", line 878, in handle_flowable
    self.handle_frameEnd()
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/reportlab/platypus/doctemplate.py", line 728, in handle_frameEnd
    self.handle_pageEnd()
  File "/Users/jack.burridge/Dev/s2c/venv/lib/python3.10/site-packages/reportlab/platypus/doctemplate.py", line 670, in handle_pageEnd
    raise LayoutError(ident)
reportlab.platypus.doctemplate.LayoutError: More than 10 pages generated without content - halting layout.  Likely that a flowable is too large for any frame.

Is there an option to split these large flowables?

🖥 Versions

python -V Python 3.10.8

pip freeze | grep rst2pdf rst2pdf==0.101

pip freeze | grep reportlab reportlab==4.0.6

pip freeze | grep Sphinx Sphinx==7.2.6

Which operating system are you using?

uname -a

Darwin P4LQNQKHYG 21.6.0 Darwin Kernel Version 21.6.0: Sun Nov 6 23:31:13 PST 2022; root:xnu-8020.240.14~1/RELEASE_ARM64_T6000 arm64

lornajane commented 11 months ago

I'm not aware of a way to split them, but I'd like to leave this issue open in case anyone else has advice on this.