Skip to content

[Serializer] Remove AbstractObjectNormalizer::isAttributeToNormalize #20530

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

Closed
wants to merge 2 commits into from

Conversation

dunglas
Copy link
Member

@dunglas dunglas commented Nov 15, 2016

Q A
Branch? 3.1
Bug fix? yes
New feature? no
BC breaks? unclear
Deprecations? no
Tests pass? yes
Fixed tickets n/a
License MIT
Doc PR n/a

I've introduced this method by error in #17113. It has been forgotten during a refactoring. It has always been unused, is not covered by our test suite and has never been documented.

Technically it's a BC break (because this is a protected method), but I think that it's better to remove it has it has never be intended to be used, it's just a miss. An alternative is to deprecate it and remove it in v4.

@fabpot
Copy link
Member

fabpot commented Nov 15, 2016

👍 to remove it as done by this PR.

@xabbuh
Copy link
Member

xabbuh commented Nov 16, 2016

I would vote for deprecating the method to prevent unexpected BC breaks for users of this class.

@fabpot
Copy link
Member

fabpot commented Nov 16, 2016

@xabbuh Is it really worth it?

@xabbuh
Copy link
Member

xabbuh commented Nov 16, 2016

Judging by the name of the method and given the fact that people will use the AbstractObjectNormalizer as the base class for their own normalizers, I fear that there will be users out there who call this method before doing actual normalisation work which would then break.

@fabpot
Copy link
Member

fabpot commented Nov 16, 2016

Ok, fair enough. Let's add a deprecation notice then.

@dunglas
Copy link
Member Author

dunglas commented Nov 16, 2016

After a quick search, I wasn't able to find any public project using this method. Regarding the fact that it was introduced in 3.1 (only 6 months ago) and is useless, I really doubt than anybody has used it.

@ro0NL
Copy link
Contributor

ro0NL commented Nov 16, 2016

Maybe add a changelog upgrade note about the silent removal of this method. As it was forgotten before...

Imo. we can totally be pragmatic on left-over code from one minor to another. But it should be documented.

@nicolas-grekas
Copy link
Member

👍 on my side for an UPGRADE entry and no deprecation.

@dunglas dunglas force-pushed the remove_isAttributeToNormalize branch from 381b731 to 63e94b4 Compare November 26, 2016 10:51
@nicolas-grekas nicolas-grekas added this to the 3.1 milestone Dec 6, 2016
@nicolas-grekas
Copy link
Member

Thank you @dunglas.

nicolas-grekas added a commit that referenced this pull request Dec 8, 2016
…oNormalize (dunglas)

This PR was squashed before being merged into the 3.1 branch (closes #20530).

Discussion
----------

[Serializer] Remove AbstractObjectNormalizer::isAttributeToNormalize

| Q             | A
| ------------- | ---
| Branch?       | 3.1
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | unclear
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

I've introduced this method by error in #17113. It has been forgotten during a refactoring. It has always been unused, is not covered by our test suite and has never been documented.

Technically it's a BC break (because this is a protected method), but I think that it's better to remove it has it has never be intended to be used, it's just a miss. An alternative is to deprecate it and remove it in v4.

Commits
-------

fea18aa [Serializer] Remove AbstractObjectNormalizer::isAttributeToNormalize
This was referenced Dec 13, 2016
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.

6 participants