Version: (using KDE 4.3.1) Installed from: Ubuntu Packages If I create a subclass of Plasma.Service and try to instantiate it I get a runtime exception: TypeError: PyKDE4.plasma.Service cannot be instantiated or sub-classed According to the api[1] it should be possible to subclass Plasma.Service. ---- - [1] http://api.kde.org/pykde-4.2-api/plasma/Plasma.Service.html - My forum post about that bug: http://forum.kde.org/viewtopic.php?f=64&t=82529
In the python-bindings Plasma.Service is marked as Abstract, Line 23 of [1] The SIP reference-Guide [2] on "QObject /Abstract/": > This boolean annotation is used to specify that the class has additional pure > virtual methods that have not been specified and so it cannot be instantiated > or sub-classed from Python I'd like to write a Dataengine that needs some additional parameters (see form-link in the initial report). Currently my Plasmoid [3] does downloading and parsing inside the gui-thread (because I cannot pass parameters to the Dataengine). This has some disadvantages for the users: - the Plasma-Desktop hangs while downloading and parsing - other plasmoids cannot reuse the functionality I checked a lot of other (scripted)-plasmoids to see how they did it (e.g. retriving data from the internet, parse and display it). They all do it in the gui-thread (gmail-plasmoid ... ) which I think is wrong. How can this problem be solved? Maybe write another bug-report on Plasma that says: Service should implement the pure virtual functions (then it would not be abstract anymore and could be subclassed). /nik [1] http://websvn.kde.org/trunk/KDE/kdebindings/python/pykde4/sip/plasma/service.sip?view=markup [2] http://doc.crossplatform.ru/python/sip/4.7.9/sipref.html#abstract [3] http://www.kde-look.org/content/show.php/Nagios+Plasmoid?content=114057
Allow the Plasma.Service class to be subclassed. WebSVN link: http://websvn.kde.org/?revision=1049796&view=revision