[PyQt] A dire warning message

Baz Walter bazwal at ftml.net
Thu Jul 7 18:36:40 BST 2011


On 07/07/11 13:00, Algis Kabaila wrote:
> On Thu, 7 Jul 2011 09:03:47 PM Hans-Peter Jansen wrote:
>>> On opening a file dialog, I get this warning:
>>>
>>> KGlobal::locale::Warning your global KLocale is being recreated with
>>> a valid main component instead of a fake component, this usually
>>> means you tried to call i18n related functions before your main
>>> component was created. You should not do that since it most likely
>>> will not work
>>>
>>> Search on the net seems to give some grim news:
>>>
>>> <quote start>
>>> Re: VLC Hangs on Open File dialog
>>> Postby Rémi Denis-Courmont » Sat Jan 29, 2011 11:58 pm
>>> In the mean time, someone in KDE actually looked at the issue.
>>> It turns to be a longstanding known bug in the QProcess class from
>>> Qt4. That bug gets triggered by a new "feature" in KDE 4.6 relative
>>> to MIME types in the Open and Save dialogs, that happens to involve
>>> the QProcess class.
>>>
>>> In the end, VLC is blaming KDE, KDE is blaming Qt, and Qt is blaming
>>> the kernel.
>>> <quote end>
>>> '''

according to that thread, the problem has been fixed in kde-4.6.1. are 
you able to upgrade?

>> Hmm, at the first glance, this is a KDE problem, since KDE plugs its own
>> file dialog into Qt, but fails to properly deal with locales there
>> after due to them not being initialized correctly. This is going to
>> produce issues, if you're calling QFileDialogs and expects them being
>> localized correctly. It might be possible to circumvent these issues by
>> instancing KApplication instead of QApplication (and doing the proper
>> KDE4 setup sequence).

yes, the problem is indirectly caused by a "compatibility" plugin that 
invokes the kde open-dialog instead of the one provided by qt.

the offending plugin is usually installed here:

      /usr/lib/kde4/plugins/gui_platform/libkde.so

personally, i always remove it whenever kde is updated.


More information about the PyQt mailing list