8000 [TypeInfo] Deprecate `CollectionType` as list and not as array by mtarld · Pull Request #59302 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[TypeInfo] Deprecate CollectionType as list and not as array #59302

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 8000 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

Merged
merged 1 commit into from
Jan 25, 2025

Conversation

mtarld
Copy link
Contributor
@mtarld mtarld commented Dec 26, 2024
Q A
Branch? 7.3
Bug fix? no
New feature? no
Deprecations? yes
Issues
License MIT

As mentioned in #59291 (comment), creating a list with a type that is not an array is not possible.

The CollectionType should reflect that, that's why this PR deprecates the creation of such types.

@xabbuh
Copy link
Member
xabbuh commented Dec 26, 2024

The test failures look related.

@mtarld
Copy link
Contributor Author
mtarld commented Dec 27, 2024

Indeed, the deprecation is triggered by the JsonEncoder component, which has tests with "iterable lists". This will be fixed in #59308

@mtarld mtarld force-pushed the feat/collection-iterable-list branch from 092d211 to 88f61c9 Compare December 28, 2024 10:44
@mtarld mtarld force-pushed the feat/collection-iterable-list branch 2 times, most recently from 3e57ac6 to 0a7c064 Compare January 6, 2025 09:24
@mtarld mtarld force-pushed the feat/collection-iterable-list branch 2 times, most recently from 9902e58 to bd44bf1 Compare January 17, 2025 07:52
@nicolas-grekas nicolas-grekas requested a review from stof January 17, 2025 13:51
@mtarld mtarld force-pushed the feat/collection-iterable-list branch from bd44bf1 to f96b1ee Compare January 17, 2025 16:38
@mtarld mtarld force-pushed the feat/collection-iterable-list branch from f96b1ee to 1136977 Compare January 17, 2025 20:46
Copy link
Member
@xabbuh xabbuh left a comment

Choose a reason for hiding this comment

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

with the last minor CS comments

@fabpot fabpot force-pushed the feat/collection-iterable-list branch from 4206fef to 50ad14d Compare January 25, 2025 09:26
@fabpot
Copy link
Member
fabpot commented Jan 25, 2025

Thank you @mtarld.

@fabpot fabpot merged commit d4566b2 into symfony:7.3 Jan 25, 2025
4 of 11 checks passed
@mtarld mtarld deleted the feat/collection-iterable-list branch January 25, 2025 09:37
@fabpot fabpot mentioned this pull request May 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development
3B4E

Successfully merging this pull request may close these issues.

5 participants
0