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
Regression since 2.4.1 #663
Comments
can you tell the exact php version you are running? |
@goetas PHP 7.2.4 on my iMac, PHP 7.1.12 on my FreeBSD production server (version constraint enforced in my composer.json). From what I see on this bug a comment from CMB caught my attention:
I did not find this information anywhere, but it seems that CMB is member of the PHP core team so this info might be considered true. In which case we should enforce the What do you think? |
😱 😱 😱 😱 😱 |
fixed by #664 |
Thanks @goetas ! |
Hello there,
I'd like to report a bug related to #657 merged in 2.4.1.
I've got a Symfony 4.1 app running on PHP 7.1+ which was using this bundle on version ^2.3.
A few months ago I have overridden the ArrayCollectionHandler the following way:
I did this because my
ArrayCollection
are generated so as to use the entity Id as key and the entity as value into myArrayCollection
s. But when these collections are serialized, I need them to be processed as a sequential array to be correctly stored and queried in ElasticSearch.Since I upgraded the bundle to 2.4.1 my subscribing handler is not called anymore, despite its
jms_serializer.subscribing_handler
tag. The originaljms_serializer.array_collection_handler
is called instead.When diving into the bundle's code, It looks like the
$sorter
closure is someway incorrect inJMS\SerializerBundle\DependencyInjection\Compiler\CustomHandlersPass::sortAndFlattenHandlersList
:When I force the use of
self::stable_uasort()
, (thus simulating a PHP5+ version), everything works correctly.Thank you,
Ben
The text was updated successfully, but these errors were encountered: