Bug 159895 - FILESAVE PDF Tagged PDF export with Forms enabled results in "Stack empty" error in PAC
Summary: FILESAVE PDF Tagged PDF export with Forms enabled results in "Stack empty" er...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.5.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: implementationError
Depends on:
Blocks: PDF-Accessibility
  Show dependency treegraph
 
Reported: 2024-02-26 07:36 UTC by Gabor Kelemen (allotropia)
Modified: 2024-03-11 11:25 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Writer (10.89 KB, application/vnd.oasis.opendocument.text)
2024-02-26 07:36 UTC, Gabor Kelemen (allotropia)
Details
The example file exported as PDF from current master (18.77 KB, application/pdf)
2024-02-26 07:36 UTC, Gabor Kelemen (allotropia)
Details
Screenshot of the example document and the PAC error message (81.81 KB, image/png)
2024-02-26 07:37 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2024-02-26 07:36:03 UTC
Created attachment 192770 [details]
Example file from Writer

Attached example file contains two content controls (the bug does not happen with only one). When this is exported as tagged PDF with the Create PDF Form option enabled, PAC tools PDF/UA check will fail with the message "Stack empty".

1. Open attached file (or attachment 186881 [details] from bug 154984 to test with every supported content controls)
2. Export as PDF, with the Tagged PDF and Create PDF forms options enabled.
3. Open the resulting PDF (or  attachment 186882 [details] from bug 154984 ) in the PAC 2021 tool
-> "Stack empty" exception box appears early in the checking, indicating there is some internal inconsistency in the exported PDF.
If the PDF/UA option is also enabled, or the Create PDF form option is not enabled, this error does not happen.

Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 8eee7eab8087590aa19bb9989c294e9be767f356
CPU threads: 15; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: default

Seems to have started in 7.5 with:

https://git.libreoffice.org/core/+/6b2433f3b66c1f118dabcd40924122deb2d4f204

author	Miklos Vajna <vmiklos@collabora.com>	Wed Sep 14 08:35:28 2022 +0200
committer	Miklos Vajna <vmiklos@collabora.com>	Wed Sep 14 10:08:04 2022 +0200

sw content controls, dropdown: add PDF export
Comment 1 Gabor Kelemen (allotropia) 2024-02-26 07:36:26 UTC
Created attachment 192771 [details]
The example file exported as PDF from current master
Comment 2 Gabor Kelemen (allotropia) 2024-02-26 07:37:40 UTC
Created attachment 192772 [details]
Screenshot of the example document and the PAC error message
Comment 3 Stéphane Guillou (stragu) 2024-03-11 11:25:57 UTC
reproduced with PDF exported with:

Version: 24.2.1.2 (X86_64) / LibreOffice Community
Build ID: db4def46b0453cc22e2d0305797cf981b68ef5ac
CPU threads: 4; OS: Windows 10.0 Build 22631; UI render: Skia/Raster; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: threaded

and analysed with PAC 21.0.0.0.