Bug #33148

CLDR locale chaining doesn't work correctly

Added by Adrian Föder almost 10 years ago. Updated over 9 years ago.

Status:
Resolved
Priority:
Must have
Category:
I18n
Start date:
2012-01-12
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
No
Complexity:
medium

Description

Simply said, the chaining in order to get also de.xml when de_DE.xml is asked for, doesn't work correctly.

The problem is mostly that the CldrRepository's findLocaleChain() that is responsible for that functionality, relies on a function localizationService->getParentLocaleOf(); while this function asks a localeCollection that never seems being populated correctly.

I'll add a test that should describe it better; anyhow I don't know if the mocking is correct (show inline PHP comment)

#1

Updated by Adrian Föder almost 10 years ago

Test is here: https://review.typo3.org/#change,7750
Please disregard the "Depends on"; just see the test.

https://review.typo3.org/#change,7761

#2

Updated by Karsten Dambekalns almost 10 years ago

  • Status changed from New to Accepted
  • Assignee set to Karsten Dambekalns
#3

Updated by Karsten Dambekalns over 9 years ago

The use of getParentLocaleOf() in the CldrRepository is wrong - as it only contains Locales for which resources actually exist. For CLDR data the case is different, the handling needs to be adjusted.

#4

Updated by Karsten Dambekalns over 9 years ago

  • Subject changed from Locale Chaining doesn't work correctly to CLDR locale chaining doesn't work correctly
#5

Updated by Gerrit Code Review over 9 years ago

  • Status changed from Accepted to Under Review

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/7761

#6

Updated by Gerrit Code Review over 9 years ago

Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/7761

#7

Updated by Gerrit Code Review over 9 years ago

Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/7761

#8

Updated by Gerrit Code Review over 9 years ago

Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/7761

#9

Updated by Adrian Föder over 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF