Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Serializer] Allow multi-dimenstion object array in AbstractObjectNormalizer #32832

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

Conversation

alediator
Copy link
Contributor

Modify ´AbstractObjectNormalizer´ adding the capability of parsing nested arrays of objects instead of parsing them into arrays

Q A
Branch? 4.3
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #31175
License MIT

I was trying to parse a nested array of objects and I'd find out with this #31175 behavior. After trying to solve in different ways, I was able to do it adding the fix that allows the AbstractObjectNormalizer to parse more than one dimension array of objects.

I would like to add some tests to assure it works and doesn't generate any side effects, but I'd prefer to open the PR to link it to the existing issue #31175.

On the other hand, if you think it is not applicable or you want me to change anything, please let me know.

@nicolas-grekas nicolas-grekas added this to the 4.3 milestone Jul 31, 2019
@nicolas-grekas nicolas-grekas changed the title Allow multi-dimenstion object array in AbstractObjectNormalizer [Serializer] Allow multi-dimenstion object array in AbstractObjectNormalizer Jul 31, 2019
@alediator
Copy link
Contributor Author

I have added some additional fixes and a test in the normalizer

@alediator
Copy link
Contributor Author

I could fix the test just switching the type of the intMatrix to 'array', but then we are saying that typing as int[][] is not possible.

What do you think?

Copy link
Member

@dunglas dunglas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@fabpot fabpot force-pushed the serializer_multi_dimension_array_denormalization_4.3 branch from 603f39f to ea03f6d Compare September 8, 2019 07:15
@fabpot fabpot changed the base branch from 4.3 to 4.4 September 8, 2019 07:15
@fabpot
Copy link
Member

fabpot commented Sep 8, 2019

Thank you @alediator.

@OskarStark
Copy link
Contributor

One question, it was submitted as bugfix, but merged into 4.4. Was this intended or a mistake, because there are no additional infos in the comments, if this was considered a new feature 🤔

cc @fabpot

@fabpot
Copy link
Member

fabpot commented Sep 8, 2019

adding the capability of parsing nested arrays of objects sounded like a new feature to me, that's why it was merged in 4.4.

@alediator
Copy link
Contributor Author

It was a pleasure to collaborate with this huge community!

@alediator alediator deleted the serializer_multi_dimension_array_denormalization_4.3 branch September 9, 2019 06:39
@fabpot fabpot mentioned this pull request Nov 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants