[PyQt] Exception while running metaSIP

Phil Thompson phil at riverbankcomputing.com
Thu Nov 1 17:27:35 GMT 2012


On Tue, 30 Oct 2012 14:50:14 +0100, Luca Beltrame
<einar at heavensinferno.net> wrote:
> Hello,
> 
> I'm trying to run MetaSIP, but I keep on hitting this exception:
> 
> $ msip
> Traceback (most recent call last):
>   File "/usr/bin/msip", line 228, in <module>
>     rc = launchGUI(prjname, guiargs)
>   File "/usr/bin/msip", line 145, in launchGUI
>     view = view_factory()
>   File "/usr/lib/python2.7/site-packages/dip/ui/view_factory.py", line
88,
>   in
> __call__
>     view = self.create(model, controller, parent)
>   File
"/usr/lib/python2.7/site-packages/dip/shell/base_shell_factory.py", 
> line 68, in create
>     view = self.create_shell(model, controller, parent)
>   File "/usr/lib/python2.7/site-
> packages/dip/shell/shells/main_window/main_window_shell.py", line 43, in

> create_shell
>     return self.main_window(model, controller, parent)
>   File "/usr/lib/python2.7/site-packages/dip/ui/view_factory.py", line
88,
>   in
> __call__
>     view = self.create(model, controller, parent)
>   File "/usr/lib/python2.7/site-packages/dip/ui/container_factory.py",
>   line
> 85, in create
>     subviews = self.create_subviews(model, controller, view)
>   File "/usr/lib/python2.7/site-packages/dip/ui/main_window.py", line
68,
>   in
> create_subviews
>     view.menu_bar = self.menu_bar.create(model, controller, view)
>   File "/usr/lib/python2.7/site-packages/dip/ui/container_factory.py",
>   line
> 85, in create
>     subviews = self.create_subviews(model, controller, view)
>   File "/usr/lib/python2.7/site-packages/dip/ui/container_factory.py",
>   line
> 127, in create_subviews
>     subview = content.create(model, controller, view)
>   File "/usr/lib/python2.7/site-packages/dip/ui/container_factory.py",
>   line
> 88, in create
>     view.views = subviews
>   File "/usr/lib/python2.7/site-packages/dip/model/value_type.py", line
>   201,
> in __set__
>     value = self.validate(value)
>   File "/usr/lib/python2.7/site-packages/dip/model/list.py", line 93, in

> validate
>     return ListImpl(self, self.validated_list(value))
>   File "/usr/lib/python2.7/site-packages/dip/model/list.py", line 116,
in 
> validated_list
>     for v in value]
>   File "/usr/lib/python2.7/site-packages/dip/model/collection_type.py",
>   line
> 60, in validate_collection_value
>     return contained_type.validate(value)
>   File "/usr/lib/python2.7/site-packages/dip/model/instance.py", line
90,
>   in
> validate
>     validated = self.validate_collection_value(instance_type, value)
>   File "/usr/lib/python2.7/site-packages/dip/model/collection_type.py",
>   line
> 47, in validate_collection_value
>     adapted = contained_type(value, exception=False)
>   File
>   "/usr/lib/python2.7/site-packages/dip/model/interface_metaclass.py",
> line 66, in __call__
>     return object_adapter(obj, cls, adapt, cache, exception)
>   File
"/usr/lib/python2.7/site-packages/dip/model/adapter_internals.py",
>   line
> 97, in object_adapter
>     adapter, adapter_cache = _find_adapter(adaptee, interface,
exception)
>   File
"/usr/lib/python2.7/site-packages/dip/model/adapter_internals.py",
>   line
> 67, in _find_adapter
>     adapter_cache = _get_adapter_cache(adaptee)
>   File
"/usr/lib/python2.7/site-packages/dip/model/adapter_internals.py",
>   line
> 61, in _get_adapter_cache
>     return [] if adaptee is None else
>     adaptee.__dict__.get('_dip_adapters',
> [])
> AttributeError: 'str' object has no attribute '__dict__'
> 
> I keep on getting this regardless of the dip version installed (current
hg
> or 
> 0.4.4) and with either python 2.7 or python 3.3.
> 
> Where should I look for to get the cause of the error?

metasip is a Python3 application. I use it (with Python v3.3, dip v0.4.4)
all the time without problems.

Phil


More information about the PyQt mailing list