Bug 891489 - anaconda cannot find matching keyboard layouts for several languages, sets them to U.S. English
Summary: anaconda cannot find matching keyboard layouts for several languages, sets th...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: anaconda
Version: 18
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Vratislav Podzimek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: AcceptedNTH
Depends On:
Blocks: F18-accepted, F18FinalFreezeExcept
TreeView+ depends on / blocked
 
Reported: 2013-01-03 06:33 UTC by Adam Williamson
Modified: 2013-01-09 09:06 UTC (History)
9 users (show)

Fixed In Version: anaconda-18.37.11-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-01-08 21:32:29 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 893135 0 unspecified CLOSED switching from English to Spanish from the two default created keyboard results in still using English (workaround=remov... 2021-02-22 00:41:40 UTC

Internal Links: 893135

Description Adam Williamson 2013-01-03 06:33:23 UTC
I went through every language offered on the very first page of the installer, checking the 'Set keyboard to default layout for selected language.' checkbox each time and proceeding to the main hub to see what keyboard would be selected. Here are the languages I found appeared to have a 'matching' layout available, but which anaconda did not find: it just set the keyboard layout to U.S. English.

Catalan (Spain)
Greek (Greece)
Spanish (Spain)
Malay (Malaysia)
Dutch (Netherlands)

For the following languages spoken in Spain, there is no 'native' layout, but they should be set to a Spanish layout, per http://www.unilang.org/viewtopic.php?f=57&t=38808 :

Basque (Spain)
Galician (Spain)

In all the above cases, if you pick the language, check the 'Set keyboard to default layout for selected language' box, and proceed to the hub, the keyboard layout will be set to U.S. English.

Proposing as NTH, some of these are pretty common languages.

Comment 1 Vratislav Podzimek 2013-01-03 12:28:53 UTC
(In reply to comment #0)
> I went through every language offered on the very first page of the
> installer, checking the 'Set keyboard to default layout for selected
> language.' checkbox each time and proceeding to the main hub to see what
> keyboard would be selected. Here are the languages I found appeared to have
> a 'matching' layout available, but which anaconda did not find: it just set
> the keyboard layout to U.S. English.
> 
> Catalan (Spain)
> Greek (Greece)
> Spanish (Spain)
> Malay (Malaysia)
> Dutch (Netherlands)
The problem with these is, that when getting layouts for languages by using libxklavier, these languages are returned as "Greek, Modern (1453-)", "Catalan; Valencian", etc. Thus they are not exactly matching the languages "Greek", "Catalan", etc.. Sending a patch that adds a fallback if no exact match is found that accepts the "libxklavier's languages" even if they just start with the same string as the given language (from the language selection).

> 
> For the following languages spoken in Spain, there is no 'native' layout,
> but they should be set to a Spanish layout, per
> http://www.unilang.org/viewtopic.php?f=57&t=38808 :
> 
> Basque (Spain)
> Galician (Spain)
I'm sorry, but this would need a mapping from languages to layouts which is something we are trying to avoid for many reasons in Anaconda. Though I believe there should be a package with these mappings maintained by the i18n team(s).

Comment 2 Adam Williamson 2013-01-03 19:50:00 UTC
Discussed at 2012-01-03 go/no-go meeting: http://meetbot.fedoraproject.org/fedora-meeting-1/2013-01-03/f18_final_gono-go_meeting.2013-01-03-17.01.log.txt . Accepted as NTH: this should be a safe fix and improves keyboard mapping during install which is obviously desirable and not fixable with an update.

Comment 3 Vratislav Podzimek 2013-01-05 13:58:16 UTC
Patch pushed to both master and f18-branch.

Comment 4 Adam Williamson 2013-01-07 23:05:50 UTC
On commit, this was marked as fixing 891487, not 891489. The commit msg could be fixed to avoid confusing people in future.

commit 0d86fb37458c824b0c722c99bc9c87834c42adc7
Author: Vratislav Podzimek <vpodzime>
Date:   Thu Jan 3 13:29:08 2013 +0100

    Try fallback if none exactly matching language is found (#891487)
    
    From the language selection we get e.g. "Greek" as a language name. But
    while iterating over all languages libxklavier knows we get "Greek, Modern
    (1453-)" which is not an exact match. If exact match is not found we should
    try to find language starting with the string we got from the language
    selection.

Comment 5 Fedora Update System 2013-01-08 01:19:21 UTC
anaconda-18.37.11-1.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/anaconda-18.37.11-1.fc18

Comment 6 Vratislav Podzimek 2013-01-08 09:51:35 UTC
(In reply to comment #4)
> On commit, this was marked as fixing 891487, not 891489. The commit msg
> could be fixed to avoid confusing people in future.
Good catch, I've used the wrong number. But I'm afraid we cannot do anything about it because fedorahosted doesn't allow backward changes.

Comment 7 Kamil Páral 2013-01-08 13:36:44 UTC
Fixed except for Malay, which caused bug 893026.

Comment 8 Adam Williamson 2013-01-08 19:18:45 UTC
Note a couple of incorrect results of this tweak:

'Northern Sotho' locale (which is a South African region) gives 'Northern Sami' keyboard (which is a Finnish dialect).

'Malay (Malaysia)' locale gives 'Malayalam (India)' keyboard layout; Malay and Malayalam are not related. (Actually it causes a crash - 893026 - but when you fix the crash, you get Malayalam).

Heuristics: never quite right. :)

Comment 9 Jaroslav Reznik 2013-01-08 19:37:09 UTC
So do we want to revert or again - tradeoff of better support for common locales vs Northern Sotho an Malay (so +1 language, for some people it could be that overbalance I expect)?

Comment 10 Fedora Update System 2013-01-08 21:32:32 UTC
anaconda-18.37.11-1.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 11 Adam Williamson 2013-01-08 21:44:26 UTC
I think it's okay to leave this fix in. The locales that are fixed are more important than the ones that broke. CLOSED is the correct status as things stand, as the code to fix this bug is in 18.37.11 and does fix the bug: it introduces a new bug, but that is being properly tracked in a new report.


Note You need to log in before you can comment on or make changes to this bug.