Similar to https://bugs.kde.org/show_bug.cgi?id=392059 Log file: https://pastebin.com/Y3iDzihM
Copy pasting said log here: ----------- TypeError Python 3.5.3: /usr/bin/python3 Mon Mar 19 17:58:48 2018 A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred. /usr/share/krita/pykrita/tenscripts/tenscripts.py in initialize(self=<tenscripts.tenscripts.TenScriptsExtension object>) 35 def initialize(self): 36 self.uitenscripts = uitenscripts.UITenScripts() 37 self.uitenscripts.initialize(self) 38 39 def readSettings(self): self = <tenscripts.tenscripts.TenScriptsExtension object> self.uitenscripts = <tenscripts.uitenscripts.UITenScripts object> self.uitenscripts.initialize = <bound method UITenScripts.initialize of <tenscripts.uitenscripts.UITenScripts object>> /usr/share/krita/pykrita/tenscripts/uitenscripts.py in initialize(self=<tenscripts.uitenscripts.UITenScripts object>, tenscripts=<tenscripts.tenscripts.TenScriptsExtension object>) 41 self.tenscripts = tenscripts 42 43 self._loadGridLayout() 44 self._fillScripts() 45 self = <tenscripts.uitenscripts.UITenScripts object> self._loadGridLayout = <bound method UITenScripts._loadGridLayout of <tenscripts.uitenscripts.UITenScripts object>> /usr/share/krita/pykrita/tenscripts/uitenscripts.py in _loadGridLayout(self=<tenscripts.uitenscripts.UITenScripts object>) 95 def _loadGridLayout(self): 96 for item in range(0, 10): 97 self.addNewRow(item) 98 99 def _fillScripts(self): self = <tenscripts.uitenscripts.UITenScripts object> self.addNewRow = <bound method UITenScripts.addNewRow of <tenscripts.uitenscripts.UITenScripts object>> item = 0 /usr/share/krita/pykrita/tenscripts/uitenscripts.py in addNewRow(self=<tenscripts.uitenscripts.UITenScripts object>, key=0) 62 63 directoryTextField.setReadOnly(True) 64 label.setText(self.tenscripts.actions[key].shortcut()) 65 directoryTextField.setToolTip("Selected Path") 66 directoryDialogButton.setToolTip("Select the script") label = <PyQt5.QtWidgets.QLabel object> label.setText = <built-in method setText of QLabel object> self = <tenscripts.uitenscripts.UITenScripts object> self.tenscripts = <tenscripts.tenscripts.TenScriptsExtension object> self.tenscripts.actions = [<PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>, <PyQt5.QtWidgets.QWidgetAction object>] key = 0 ].shortcut undefined TypeError: setText(self, str): argument 1 has unexpected type 'QKeySequence' __cause__ = None __class__ = <class 'TypeError'> __context__ = None __delattr__ = <method-wrapper '__delattr__' of TypeError object> __dict__ = {} __dir__ = <built-in method __dir__ of TypeError object> __doc__ = 'Inappropriate argument type.' __eq__ = <method-wrapper '__eq__' of TypeError object> __format__ = <built-in method __format__ of TypeError object> __ge__ = <method-wrapper '__ge__' of TypeError object> __getattribute__ = <method-wrapper '__getattribute__' of TypeError object> __gt__ = <method-wrapper '__gt__' of TypeError object> __hash__ = <method-wrapper '__hash__' of TypeError object> __init__ = <method-wrapper '__init__' of TypeError object> __le__ = <method-wrapper '__le__' of TypeError object> __lt__ = <method-wrapper '__lt__' of TypeError object> __ne__ = <method-wrapper '__ne__' of TypeError object> __new__ = <built-in method __new__ of type object> __reduce__ = <built-in method __reduce__ of TypeError object> __reduce_ex__ = <built-in method __reduce_ex__ of TypeError object> __repr__ = <method-wrapper '__repr__' of TypeError object> __setattr__ = <method-wrapper '__setattr__' of TypeError object> __setstate__ = <built-in method __setstate__ of TypeError object> __sizeof__ = <built-in method __sizeof__ of TypeError object> __str__ = <method-wrapper '__str__' of TypeError object> __subclasshook__ = <built-in method __subclasshook__ of type object> __suppress_context__ = False __traceback__ = <traceback object> args = ("setText(self, str): argument 1 has unexpected type 'QKeySequence'",) with_traceback = <built-in method with_traceback of TypeError object> The above is a description of an error in a Python program. Here is the original traceback: Traceback (most recent call last): File "/usr/share/krita/pykrita/tenscripts/tenscripts.py", line 37, in initialize self.uitenscripts.initialize(self) File "/usr/share/krita/pykrita/tenscripts/uitenscripts.py", line 43, in initialize self._loadGridLayout() File "/usr/share/krita/pykrita/tenscripts/uitenscripts.py", line 97, in _loadGridLayout self.addNewRow(item) File "/usr/share/krita/pykrita/tenscripts/uitenscripts.py", line 64, in addNewRow label.setText(self.tenscripts.actions[key].shortcut()) TypeError: setText(self, str): argument 1 has unexpected type 'QKeySequence'
That's a conversion error, I will fix that today. Which steps did you take to get this error?
Oh, I have already a patch, basically, with the move from Action to QAction, the shortcut needs a toString() appended.
Git commit 8caa7dcd9b9308af8da9f2b1cbae0e6bc1e84c5f by Boudewijn Rempt. Committed on 19/03/2018 at 14:31. Pushed by rempt into branch 'master'. Fix change from Action to QAction shortcut is no longer a string but a QKeySequence, so it needs a toString() Related: bug 392059 M +9 -9 plugins/python/tenbrushes/uitenbrushes.py M +1 -1 plugins/python/tenscripts/uitenscripts.py https://commits.kde.org/krita/8caa7dcd9b9308af8da9f2b1cbae0e6bc1e84c5f
Git commit 7aa7373e4935689c5bdd90da760771ec2de1bc1b by Boudewijn Rempt. Committed on 19/03/2018 at 14:32. Pushed by rempt into branch 'krita/4.0'. Fix change from Action to QAction shortcut is no longer a string but a QKeySequence, so it needs a toString() Related: bug 392059 M +9 -9 plugins/python/tenbrushes/uitenbrushes.py M +1 -1 plugins/python/tenscripts/uitenscripts.py https://commits.kde.org/krita/7aa7373e4935689c5bdd90da760771ec2de1bc1b
It's ok. Thanks, Boud. :)