ezyang / htmlpurifier

Standards compliant HTML filter written in PHP
http://htmlpurifier.org
GNU Lesser General Public License v2.1
3.03k stars 323 forks source link

Fix some more PHP 8.2 deprecations #330

Closed TimWolla closed 1 year ago

TimWolla commented 1 year ago

Read the description in #319 for more details.


At this point fixing more issues gets painful, because some of the errors are in simpletest and not obvious to fix to me. Unfortunately simpletest's own tests already fail even with PHP 7.4 making it even harder to make the necessary changes.

It might make sense to migrate HTMLPurifier's tests to another maintained testing framework (e.g. PHPUnit) to future proof it for upcoming PHP versions (I specifically can imagine PHP 9 being painful once it appears). Unfortunately I don't have the time resources that are necessary to make this happen.

bytestream commented 1 year ago

At this point fixing more issues gets painful, because some of the errors are in simpletest and not obvious to fix to me.

When running htmlpurifier's tests on php:8.2-rc-cli I'm only seeing 1 deprecation notice - https://github.com/ezyang/simpletest/pull/3

After the above, and the changes in this PR, there's 189 other failures all of Creation of dynamic property. So the fixes should be simple.