PHP 5.5.13 breaks backwards compatibility

There’s a backwards compatibility break in PHP 5.5.13 (and PHP 5.4.29) affecting PHPUnit, Mockery, Doctrine, Symfony and probably a lot more.
Rafael Dohms triggered me with this Tweet;

And I just ran into the issues with Mockery/PHPUnit;

Failed asserting that exception of type "PHPUnit_Framework_Error_Warning" matches expected exception "SymfonyComponentHttpKernelExceptionNotFoundHttpException". 
Message was: "Erroneous data format for unserializing 'Mockery_9_Symfony_Component_HttpFoundation_File_UploadedFile'".

I found the following sources that explain what happened:

I advise to not upgrade to PHP5.5.13 but wait for PHP5.5.14, it should be released soon.

Update June 19

This is the answer from on my question when 5.5.14 gets released;

Update June 29

The good news: PHP5.5.14 is released with the following note:

Please, note that this release also fixes a backward compatibility issue that has been detected in the PHP 5.5.13 release. Still, the fix in PHP 5.5.14 may break some very rare situations. As this tiny compatibility break involves security, and as security is our primary concern, we had to fix it. This concerns bug 67072. For more information about this bug and its actual resolution, please visit our upgrading guide. We apologize for any inconvenience you may have experienced with this behavior.

The bad news: It doesn’t fix the ‘Erroneous data format’ error!
I guess we’ll have to wait another month for the next release.

Update September 24

To round-up this post; I’m currently running PHP5.5.17 and the errors are gone! Hurray!

Leave a Reply