WeasyPrint: IndexError: tuple index out of range with weasyprint 50
After upgrading to 50 from 49 I got the following error when generating a PDF:
IndexError: tuple index out of range
[...]
File "weasyprint/layout/blocks.py", line 63, in block_level_layout
page_is_empty, absolute_boxes, fixed_boxes, adjoining_margins)
File "weasyprint/layout/blocks.py", line 77, in block_level_layout_switch
page_is_empty, absolute_boxes, fixed_boxes, adjoining_margins)
File "weasyprint/layout/blocks.py", line 130, in block_box_layout
absolute_boxes, fixed_boxes, adjoining_margins)
File "weasyprint/layout/blocks.py", line 376, in block_container_layout
for line, resume_at in lines_iterator:
File "weasyprint/layout/inlines.py", line 53, in iter_line_boxes
absolute_boxes, fixed_boxes, first_letter_style)
File "weasyprint/layout/inlines.py", line 70, in get_next_linebox
skip_stack = skip_first_whitespace(linebox, skip_stack)
File "weasyprint/layout/inlines.py", line 210, in skip_first_whitespace
result = skip_first_whitespace(box.children[index], next_skip_stack)
Downgrading to 49 prevents this error. Possibly similar to #783? I will try to come up with a test case when I find some time.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 1
- Comments: 15 (8 by maintainers)
Commits related to this issue
- Sanitize simplified line breaking The special case that an already broken child must be split again confronts us with two skip stacks: The initial (absolute) and the adjusted (partial) stack. Often t... — committed to Tontyna/WeasyPrint by Tontyna 5 years ago
- Downgrade Weasyprint to fix a bug See https://github.com/Kozea/WeasyPrint/issues/953 — committed to GeotrekCE/Geotrek-admin by deleted user 5 years ago
- HOT-FIX: atualiza Weasyprint por conta de bug e requirements.txt Atualiza Weasyprint por conta do bug https://github.com/Kozea/WeasyPrint/issues/953 E também atualiza requirements porque rede senado... — committed to interlegis/sapl by edwardoliveira 4 years ago
- HOT-FIX: atualiza Weasyprint por conta de bug e requirements.txt Atualiza Weasyprint por conta do bug https://github.com/Kozea/WeasyPrint/issues/953 E também atualiza requirements porque rede senado... — committed to interlegis/sapl by edwardoliveira 4 years ago
- Squash dos commits da master Update instalacao31.rst (#2292) 2486 django channels (#2523) * config inicial * impl channels tutorial 1 e 2 * corrige versão do redis * impl tutorial 3 * impl time... — committed to interlegis/sapl by cantuariavc 6 years ago
I tried it out, and #956 does fix the conversion time! Back the 30seconds for the whole novel, just like in WeasyPrint 49.