Git commit 8c5902e49b6387c3c2e82c475ff5a1f491da7604 by Harald Sitter.
Committed on 06/12/2013 at 09:11.
Pushed by sitter into branch 'KDE/4.11'.

Fix traceback in Python runner plugins

Plamascript.Runner is the base of python krunner plugins. These plugins
implement the C++ signals prepare, teardown, createRunOptions and
reloadConfiguration in actual methods (the signal wiring happens in
pyrunner.py which is the loading component). As a result of this calls
to any of these methods will fall through to plasmascript.Runner whenever
the actual runner does not implement them. However plasmascript.Runner is
missing the implicit 'self' argument such that one gets silly python
backtraces like

File "/usr/share/kde4/apps/plasma_scriptengine_python/pyrunner.py", line 90, in 
reloadConfiguration
    self.pyrunner.reloadConfiguration()

To prevent this from happening the functions now have the implicit self
argument.

Also see:
https://bugs.launchpad.net/ubuntu/+source/kde-workspace/+bug/1258088

CCMAIL: 1258...@bugs.launchpad.net
REVIEW: 114314

M  +4    -4    plasma/generic/scriptengines/python/plasmascript.py

http://commits.kde.org/kde-
workspace/8c5902e49b6387c3c2e82c475ff5a1f491da7604

diff --git a/plasma/generic/scriptengines/python/plasmascript.py 
b/plasma/generic/scriptengines/python/plasmascript.py
index 0ec38eb..ba149cf 100644
--- a/plasma/generic/scriptengines/python/plasmascript.py
+++ b/plasma/generic/scriptengines/python/plasmascript.py
@@ -212,14 +212,14 @@ class Runner(QObject):
     def run(self, search, action):
         pass
 
-    def prepare():
+    def prepare(self):
         pass
 
-    def teardown():
+    def teardown(self):
         pass
 
-    def createRunOptions(widget):
+    def createRunOptions(self, widget):
         pass
 
-    def reloadConfiguration():
+    def reloadConfiguration(self):
         pass

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1258088

Title:
  /usr/bin/krunner:TypeError:reloadConfiguration

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/kde-workspace/+bug/1258088/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to