8000 xml_set_*_handler() deprecation fix for PHP 8.4 by laoneo · Pull Request #3563 · dompdf/dompdf · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

xml_set_*_handler() deprecation fix for PHP 8.4 #3563

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8000 Merged
merged 2 commits into from
Dec 20, 2024
Merged

Conversation

laoneo
Copy link
Contributor
@laoneo laoneo commented Dec 10, 2024

With the release of PHP 8.4, the xml_set_*_handler() function arguments must be callable or null. Otherwise is a deprecated warning thrown:

Passing non-callable strings is deprecated since 8.4

The message is a bit misleading as dompdf uses false as end handler and not a string.

@bsweeney bsweeney added this to the 3.0.2 milestone Dec 10, 2024
@williamdes
Copy link
Contributor
williamdes commented Dec 12, 2024

Is this covered by tests, I did not see it fail on 8.4 🤔

@laoneo
Copy link
Contributor Author
laoneo commented Dec 12, 2024

Don't know,but it's a deprecated warning only.

@bsweeney
Copy link
Member
bsweeney commented Dec 13, 2024

I don't think there are any tests related to SVG parsing. I'll add some tests to this PR to cover some Image::Cache use cases (unless somebody beats me to it).

bsweeney added a commit that referenced this pull request Dec 19, 2024
@bsweeney
Copy link
Member
bsweeney commented Dec 19, 2024

I went ahead and added a test case via #3564 so I will move forward with merging this. Deprecations don't currently generate errors so unless somebody was really paying attention this could have been missed even with relevant tests.

@williamdes
Copy link
Contributor

I went ahead and added a test case via #3564 so I will move forward with merging this. Deprecations don't currently generate errors so unless somebody was really paying attention this could have been missed.

Thank you!
Indeed Debian is re building packages with PHP 8.4 and php-dompdf did not fail

@laoneo
Copy link
Contributor Author
laoneo commented Dec 20, 2024

Thank you guys, in the meantime I shipped my fork with the fix.

@bsweeney bsweeney merged commit a22f3aa into dompdf:master Dec 20, 2024
12 checks passed
@laoneo laoneo deleted the patch-1 branch December 20, 2024 13:41
bsweeney added a commit that referenced this pull request Dec 20, 2024
bsweeney added a commit that referenced this pull request Dec 20, 2024
hardikradixweb pushed a commit to hardikradixweb/dompdf that referenced this pull request Mar 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0