Bug 245289

Summary: printer-applet crashed on startup
Product: [Plasma] printer-applet Reporter: Radek Novacek <rad.n>
Component: generalAssignee: Jonathan Riddell <jr>
Status: RESOLVED FIXED    
Severity: crash    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Proposed patch for this issue
proposed fix based on bug 244942

Description Radek Novacek 2010-07-21 08:32:24 UTC
Created attachment 49356 [details]
Proposed patch for this issue

Version:           unspecified (using Devel) 
OS:                Linux

Printer applets crashed with following backtrace every time:

Traceback (most recent call last):
  File "/usr/bin/printer-applet", line 1163, in <module>
    applet = JobManager()
  File "/usr/bin/printer-applet", line 241, in __init__
    uic.loadUi(APPDIR + '/' + "printer-applet.ui", self.mainWindow)
  File "/usr/lib/python2.6/site-packages/PyQt4/uic/__init__.py", line 177, in loadUi
    return DynamicUILoader().loadUi(uifile, baseinstance)
  File "/usr/lib/python2.6/site-packages/PyQt4/uic/Loader/loader.py", line 24, in loadUi
    return self.parse(filename, os.path.dirname(filename))
  File "/usr/lib/python2.6/posixpath.py", line 119, in dirname
    i = p.rfind('/') + 1
AttributeError: 'QString' object has no attribute 'rfind'


Reproducible: Always

Steps to Reproduce:
Just run it.



Solution is simple, just convert QString to the python str.
Comment 1 Andrea Scarpino 2010-07-29 12:58:59 UTC
Created attachment 49628 [details]
proposed fix based on bug 244942
Comment 2 Jonathan Riddell 2010-07-29 13:18:37 UTC

*** This bug has been marked as a duplicate of bug 244942 ***
Comment 3 Jonathan Riddell 2010-07-29 13:35:18 UTC
SVN commit 1156611 by jriddell:

Workaround change in PyQt 4.7 which now expects a string not a QString
BUG:245289


 M  +2 -2      printer-applet.py  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1156611
Comment 4 Jonathan Riddell 2010-07-29 13:36:50 UTC
SVN commit 1156613 by jriddell:

backport workaround for PyQt 4.7 expecting a string not a QString
BUG:245289


 M  +2 -2      printer-applet.py  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1156613
Comment 5 Jonathan Riddell 2010-07-29 13:42:04 UTC
Tagging with kde-4.5.0-blocker incase dirk fancies remaking the kdeutils tar with this fix.