Closed dominiquegerber closed 8 months ago
I had this too, but it was fixed within the current version 8 of the library.
Good to know thanks. Unfortunately version 8 of the lib requires to use symphony 7 as well, which we haven't migrated to yet. Ahh damn domino effect !
Yeah and i do not fully understand why the compatibility to Symfony 6 should not be there anymore 🤔 Maybe one should try it with symfony constraints to ^6.0|^7.0
in composer file and if it works open a PR to re-enable wider symfony version constraints.
Ok. I did it.
https://github.com/krowinski/php-mysql-replication/pull/113
Let's see if it gets merged.
merged
SELECT VERSION();
): 10.3.39-MariaDB-0ubuntu0.20.04.2-logDecoding of a date field.
The decoded date field
The offending line in RowEvent.php :
if (array_sum(DateTime::getLastErrors()) > 0) {
which produces the (fatal) error
This is due to a change in the return type of DateTime::getLastErrors in PHP8.2 as indicated in the official documentation: (https://www.php.net/manual/en/datetimeimmutable.getlasterrors.php) :
I imagine that a simple cast to array should solve this issue, (array )false produces an empty array which would "array_sum" to 0.