#108427TYPO3 backend login broken when xlf file not translated properly
Description
Today the TYPO3 backend login was broken for several users of the German translation of TYPO3 because a label in the XLF files was not translated properly.
Reason was that in Crowdin the id “free_software_and_warranty” from EXT:backend/Resources/Private/Language/locallang_login.xlf was translated without keeping %s for sprintf.
English:
TYPO3 CMS comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions, see %sdetails about licenses.%s
Broken German translation:
TYPO3 CMS wird OHNE JEGLICHE GEWÄHRLEISTUNG bereitgestellt. Es handelt sich um freie Software, die du unter bestimmten Bedingungen weiterverbreiten darfst. Weitere Informationen findest du unter %sdetails about licenses.%
After the last % the s is missing.
This lead to an exception when a backend user tried to login into TYPO3:
> ValueError
> Missing format specifier at end of string
vendor/typo3/cms-core/Classes/Information/Typo3Information.php line 98
The broken translation was introduced Dec 07, 22:08 and fixed Dec 08, 9:07. So only a small number of users should be affected. Mostly those who do updates of language files during deployment.
The TYPO3 Localization Team will improve the documentation and increase the awareness for translators and especially proofreaders to keep an eye on %s in labels during translation.
But maybe it’s also possible to improve the TYPO3 core to better detect broken labels and fallback to english and log the error only.
Reviews 1
Related issues 3
- Bug #106402Critical error in LocalizationUtility.php when accessing Backend Users in Spanish
- Bug #108424Backend login crashes with ValueError in sprintf() when German translation is used (invalid format string for free_software_and_warranty)
- Bug #108466Properly throw ValueError in locallang translate handling