Dolibarr / dolibarr

Dolibarr ERP CRM is a modern software package to manage your company or foundation's activity (contacts, suppliers, invoices, orders, stocks, agenda, accounting, ...). it's an open source Web application (written in PHP) designed for businesses of any sizes, foundations and freelancers.
https://www.dolibarr.org
GNU General Public License v3.0
5.47k stars 2.8k forks source link

Libreoffice 24 will produce corrupted ODT with Dolibarr #31708

Open warnerbryce opened 1 week ago

warnerbryce commented 1 week ago

Bug

Tested on Dolibarr 16 / 19 / dev Nginx and PHP 7.4 and 8.2 (for 19 and dev)

With Libreoffice 24 installed, the ODT generated via Dolibarr won't convert into PDF. When opening the ODT file with Libreoffice you get an error message asking if you want to recover the file. You can click YES and the file opens and look OK. You can't convert into PDF using the same cli as Dolibarr, you get an error "Error: source file could not be loaded"

If you keep the same setup but manage to uninstall Libreoffice 24 for installing Libreoffice 7, it works as intended.

I can't find where is the problem, it's concerning because next Debian version will have Libreoffice 24 by default.

Dolibarr Version

19.0, develop

Environment PHP

7.4 or 8.2

Environment Database

MariaDB 11.5.2

Steps to reproduce the behavior and expected behavior

Having a working Dolibarr with Libreoffice 24.x installed Having an ODT template for an invoice or propal Trying to generate an ODT and convert is with MAIN_ODT_AS_PDF = libreoffice

Attached files

No response

bafbes commented 1 day ago

Please provide an exact tag 19.0.X Develop is not a fixed branch as it evolves continuously.

warnerbryce commented 1 day ago

@bafbes you can try on 18.0.5 for exemple. i tested 16.0.5 / 19.0.2 / 20.0.1 and 21-alpha