Skip to content

[FrameworkBundle] [Validator] Legacy Translator Checking #31154

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 9 commits into from

Conversation

snebes
Copy link

@snebes snebes commented Apr 18, 2019

Q A
Branch? 4.2
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #31152, #31108
License MIT

This fixes the recent bug that was introduced in 4.2.7 with regard to the old TranslatorInterface being passed to the LegacyTranslatorProxy decorator, which isn't compatible.

ping @nicolas-grekas since you were looking for this

@snebes snebes changed the title Fwb translator error [WIP] [FrameworkBundle] Legacy Translator Checking Apr 18, 2019
@@ -19,7 +19,8 @@
"php": "^7.1.3",
"symfony/contracts": "^1.0.2",
"symfony/polyfill-ctype": "~1.8",
"symfony/polyfill-mbstring": "~1.0"
"symfony/polyfill-mbstring": "~1.0",
"symfony/translation": "~4.2"
Copy link
Author

@snebes snebes Apr 18, 2019

Choose a reason for hiding this comment

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

I moved this into the require section since LegacyTranslatorProxy includes a reference still to the old interface.

https://github.com/symfony/symfony/blob/master/src/Symfony/Component/Validator/Util/LegacyTranslatorProxy.php#L14

@snebes snebes changed the title [WIP] [FrameworkBundle] Legacy Translator Checking [WIP] [FrameworkBundle] [Validator] Legacy Translator Checking Apr 18, 2019
@snebes snebes changed the title [WIP] [FrameworkBundle] [Validator] Legacy Translator Checking [FrameworkBundle] [Validator] Legacy Translator Checking Apr 18, 2019
@nicolas-grekas
Copy link
Member

Thanks, but I don't understand why all these changes. This reintroduces the bug that is fixed by #31108

I feel like the only needed change is moving translation to the require section, isn't it?

@xabbuh
Copy link
Member

xabbuh commented Apr 18, 2019

see #31156 for an easier alternative solution

@xabbuh xabbuh added this to the 4.2 milestone Apr 18, 2019
@nicolas-grekas
Copy link
Member

Thank you @snebes, I merged #31156 instead. Next time :)

@snebes snebes deleted the fwb-translator-error branch April 18, 2019 06:41
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.

4 participants