Apologies I posted this straight into the bugs forum and then noticed the message saying it should be posted here first.
I've just upgraded two instances of 12.5 to 12.7 and both are now giving a 500 error when I try to produce a PDF.
I used the newish up.php process to perform the upgrades
Error in /var/log/apache2/error.log is
Undefined constant "CURLOPT_CONNECTTIMEOUT" in /var/www/database/include/tcpdf/include/tcpdf_static.php:>
Understand that tcpdf is a 3rd party tool, but this will probably hit other users soon, so thought I'd post here to assist.
Presumably the solution is to add that constant to the tcpdf_static.php file, but not sure if there's a better way. Please advise. Thanks
Running on Debian
PHP version 8.2.28
mysql version 10.11.6-MariaDB-0+deb12u1
apache2 web server
I am not aware of any PDF related bugs in v12.7. The current demo https://dadabik.com/demo runs 12.7 and the PDF generation works.
Are you sure you haven't also upgraded PHP or changed some settings? Is CURL installed on your system?
If you open /var/www/database/include/tcpdf/include/tcpdf_static.php
what do you see as "last update" (should be line 6 of the file).
I upgraded two separate servers at the same time, using the up.php process, which seemed to work fine. Both systems are now displaying the same error when I try to create pdfs. Both systems were creating PDFs fine when 12.5 was installed.
Curl is installed
Last update on line 6 of the file shows 2024-12-23
In order to pass the prerequisites for up.php, I needed to install php8.2-zip and allow www-data write access to the directory (I actually changed owner to www-data from root so I don't know if that might have created any problems)
Last update seems fine.
Could you double check if the error CURLOPT_CONNECTTIMEOUT is the one generated by your attempt to produce a PDF (exact same datetime)?
Let's see some details about CURL, please create a test.php file in the same folder where tcpdf is, edit the file adding this code