On 03/10/2011 10:17 AM, Uwe Gansert wrote: >> Honestly I'm confused from this one. I do not know what is root of >> cause? And what is wrong on >> _ = gettext.gettext >> We use it on a lot of places. So if there is some problem we may want to >> change it everywhere in code as well. > > to be honest, I'm not a python expert. I extracted that patch from another > bug > that has exactly the same failure (nothing spacewalk related) and was fixed > like that.
OK. I spent few hours on this problem... provided patch can be shortened to: _ = lambda x: unicode(gettext.gettext(x), 'utf-8')) This problem was not even with de, it happened with other languages as well. And with different commands (e.g spacewalk-channel) as well. I searched what is the cause, as the idiom _ = gettext.gettext is used very often in other projects. Adelton find the cause is python change: http://svn.python.org/view?revision=46861&view=revision And I find in python documentation that preferred idiom for translations in Unicode is: http://docs.python.org/library/gettext.html#localizing-your-module Fixed in spacewalk.git: ceb71f81a3b64d8a71781f65f9d82b88340601e8 -- Miroslav Suchy Red Hat Satellite Engineering _______________________________________________ Spacewalk-devel mailing list Spacewalk-devel@redhat.com https://www.redhat.com/mailman/listinfo/spacewalk-devel