--- Downloads/usr/lib/python2.7/site-packages/sonata/misc.py 2011-03-02 12:57:33.000000000 -0500 +++ /usr/lib/python2.7/site-packages/sonata/misc.py 2011-03-02 23:19:29.000000000 -0500 @@ -222,12 +222,11 @@ locale.setlocale(locale.LC_ALL, "") # XXX this makes python-mpd correctly return lowercase # keys for, e.g., playlistinfo() with a turkish locale: - # (and breaks playlist search with russian), - # so, added check for turkish here. - turkish = ('tr_TR',) - locale, encoding = locale.getlocale() - if locale in turkish: - locale.setlocale(locale.LC_CTYPE, "C") + # (and breaks playlist search with russian), + # so, added check for turkish here. + l, e = locale.getlocale() + if l == 'tr_TR': + locale.setlocale(locale.LC_CTYPE, "C") except: print "Failed to set locale" sys.exit(1)