problem with turkish utf8 locale

Bug #818770 reported by jfcgauss
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
langpack-locales (Ubuntu)
Triaged
Undecided
Unassigned

Bug Description

there are 4 I's in Turkish alphabet
i (small I with dot)
İ (capital I with dot, uppercase of the above)
ı (small dotless I)
I (capital dotless I, uppercase of the above)

so, unlike english, 'ı'.upper = 'I' and 'i'.upper() = 'İ'
the following python code gives wrong output on my english-installed ubuntu 11.04

# coding=utf-8
from locale import getlocale, setlocale, getdefaultlocale, LC_ALL, LC_CTYPE
setlocale(LC_ALL, 'tr_TR.UTF-8')
print 'iI'.swapcase()
print 'iıabc'.upper()

the output is:
iI
iıABC

It is like (ıiIİ) are not uppercased/caseswapped at all.

Note that I do have tr_TR.utf8 in locale -a 's output
I have installed tr_TR.utf8 with
sudo locale-gen --archive tr_TR.UTF-8

ProblemType: Bug
DistroRelease: Ubuntu 11.04
Package: locales 2.13+git20100825-4
ProcVersionSignature: Ubuntu 2.6.38-10.46-generic-pae 2.6.38.7
Uname: Linux 2.6.38-10-generic-pae i686
NonfreeKernelModules: fglrx
Architecture: i386
Date: Sun Jul 31 11:02:48 2011
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110427.1)
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=en_US:en
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: langpack-locales
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
jfcgauss (jfcgauss) wrote :
Revision history for this message
jfcgauss (jfcgauss) wrote :

/usr/share/i18n/locales/tr_TR file seems to correctly define upper/lower case relations of these 4 letters, but somehow I dont see it in action..

Martin Pitt (pitti)
Changed in langpack-locales (Ubuntu):
status: New → Triaged
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.