PySide Bugzilla Closed for New Bugs

PySide is now a Qt Add-on and uses the Qt Project's JIRA Bug Tracker instead of this Bugzilla instance. This Bugzilla is left for reference purposes.

Bug 466 - pyside-uic broken in Ubuntu; WidgetPluginError: <type 'exceptions.KeyError'>: 'pluginType'
: pyside-uic broken in Ubuntu; WidgetPluginError: <type 'exceptions.KeyError'>:...
Status: CLOSED FIXED
Product: PySide
Classification: Unclassified
Component: pyside-tools
: 0.4.2
: All Linux
: P2 blocker
Assigned To: Lauro Moura
:
:
:
  Show dependency treegraph
 
Reported: 2010-11-11 19:42 EET by Chris Morgan
Modified: 2010-11-25 17:48 EET (History)
9 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Morgan 2010-11-11 19:42:06 EET
pyside-uic from the PySide PPA in Ubuntu 10.10 (64-bit) is broken. It prints
"An unexpected error occurred." whenever you try to use it passing in a file
(valid or invalid).

Running it with -d produces this traceback:

Traceback (most recent call last):
  File "/usr/bin/pyside-uic", line 75, in main
    options.indent)
  File "/usr/bin/pyside-uic", line 39, in generateUi
    pysideuic.compileUi(uifname, pyfile, execute, indent)
  File "/usr/lib/pymodules/python2.6/pysideuic/__init__.py", line 73, in
compileUi
    winfo = compiler.UICompiler().compileUi(uifile, pyfile)
  File "/usr/lib/pymodules/python2.6/pysideuic/Compiler/compiler.py", line 37,
in __init__
    CompilerCreatorPolicy())
  File "/usr/lib/pymodules/python2.6/pysideuic/uiparser.py", line 110, in
__init__
    self.factory = QObjectCreator(creatorPolicy)
  File "/usr/lib/pymodules/python2.6/pysideuic/objcreator.py", line 79, in
__init__
    raise WidgetPluginError, "%s: %s" % (e.__class__, str(e))
WidgetPluginError: <type 'exceptions.KeyError'>: 'pluginType'

The way to fix this seems to be to remove
/usr/lib/pymodules/python2.6/pysideuic/widget-plugins/__init__.py. Not sure if
that removes any functionality, but it seems to work without it. (That
directory also contains qtwebkit.py, I haven't yet tried converting a .ui file
which uses QtWebKit; it's possible that that might not work?)
Comment 1 Chris Morgan 2010-11-16 00:52:43 EET
As I was testing PySide in Windows, I looked to see what was in its
widget-plugins directory: qtwebkit.py, qtwebkit.pyc and qtwebkit.pyo but no
__init__.py.

This makes me fairly certain that removing pysideuic/widget-plugins/__init__.py
is actually the correct solution.
Comment 2 Matti Airas 2010-11-23 06:07:04 EET
This is being worked on right now and will be fixed before the next release.
I'm increasing priority to P2 accordingly.
Comment 3 Didier Raboud 2010-11-23 13:26:28 EET
Hi, 

AFAIK this is fixed (by the use of dh_python2) in pyside-tools -
0.2.2-1~pyside2 that I just released to the official PPA.
Comment 4 Chris Morgan 2010-11-23 18:20:01 EET
Yes, that's fixed. Thanks for that.
Comment 5 Matti Airas 2010-11-24 04:41:52 EET
OK, thanks!
Comment 6 renato filho 2010-11-25 17:48:24 EET
released on 1.0.0~beta1