pontedilana / php-weasyprint

PHP library allowing PDF generation or snapshot from an URL or an HTML page. Wrapper for Kozea/WeasyPrint
MIT License
52 stars 11 forks source link

Always pass through timeout when creating a process #7

Closed mbabker closed 1 year ago

mbabker commented 1 year ago

The Symfony\Component\Process\Process class allows setting a null value for the timeout, indicating the process does not have a timeout. The generator class only configures the timeout when it is a non-null value, making it impossible to configure the generator to run without a timeout (i.e. in a command line context as a system job where a long-running process is intended).

This change allows configuring the process to have no timeout by always passing through the timeout value from the generator.

This will have no B/C impact as the generator's constructor has an explicit $this->setTimeout() call with a default timeout.

what-the-diff[bot] commented 1 year ago

PR Summary

endelwar commented 1 year ago

Thanks Michael, good catch in thisn PR.

p.s: thank for your work on Pagerfanta :)