[MGNLREST-296] Incorrect handling of three-letter IANA language locales Created: 10/Feb/21 Updated: 25/Mar/22 |
|
| Status: | Accepted |
| Project: | Magnolia REST Framework |
| Component/s: | None |
| Affects Version/s: | 2.2.6 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Neutral |
| Reporter: | Martin Drápela | Assignee: | Unassigned |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
| Template: | |
| Acceptance criteria: |
Empty
|
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
| Bug DoR: |
[X]*
Steps to reproduce, expected, and actual results filled
[X]*
Affected version filled
|
| Date of First Response: |
| Description |
Steps to reproduce
class: info.magnolia.rest.delivery.jcr.v2.JcrDeliveryEndpointDefinition workspace: website bypassWorkspaceAcls: true rootPath: /travel/book-tour/ nodeTypes: - mgnl:page
Result returned - the (three-letter?) locale "is not allowed": {
"error": {
"code": "badRequest",
"message": "Language parameter: szl is not allowed"
}
}
Expected (part) is: {
"@name": "meal",
"@path": "/travel/book-tour/meal",
"@id": "9b8ea1b2-a93f-4015-a822-84d730ca982a",
"@nodeType": "mgnl:page",
"hideInNav": "true",
"title": "Krutipysk",
"@nodes":[]
}
Result returned - notice that it includes also the szl variant: {
"@name": "meal",
"@path": "/travel/book-tour/meal",
"@id": "9b8ea1b2-a93f-4015-a822-84d730ca982a",
"@nodeType": "mgnl:page",
"hideInNav": "true",
"title": "Menü",
"title_szl": "Krutipysk",
"@nodes":[]
}
Expected (part) is: {
"@name": "meal",
"@path": "/travel/book-tour/meal",
"@id": "9b8ea1b2-a93f-4015-a822-84d730ca982a",
"@nodeType": "mgnl:page",
"hideInNav": "true",
"title": "Menü",
"@nodes":[]
}
Possible impact of the issue May affect for example the speakers of Chinese who would like to configure in a specific variant rather then the zh macrolanguage locale: Note: The IANA subtag registry lists:
|
| Comments |
| Comment by Christopher Zimmermann [ 16/Feb/22 ] |
|
jsimak do you think this problem might been improved at all with latest fix with country codes - welsh thing? |
| Comment by Jaroslav Simak [ 16/Feb/22 ] |
|
czimmermann I don't know, this needs to be verified. |