[Zope3-Users] Error on adding an index: "ComponentLookupError: (<InterfaceClass zope.app.intid.interfaces.IIntIds>, '') "

Thierry Florac thierry.florac at onf.fr
Wed May 6 05:54:47 EDT 2009


======================================================================
Le mercredi  6 mai 2009,
  Chetan Kumar <chetan.mlist at gmail.com> a écrit :

> On Wed, May 6, 2009 at 1:17 PM, Thierry Florac
> <thierry.florac at onf.fr> wrote: ...
> > Did you register your "ind" component as default provider of IIntIds
> > interface ??
> 
> The intent is to register this component as provider of IIntIds. I
> see this
> 
> ====================
> >>> sm.registerUtility(ind, intid.IntIds)
> Traceback (most recent call last):
>   File "<console>", line 1, in ?
>   File
> "/home/xpmt/.buildout/eggs/zope.component-3.4.0-py2.4.egg/zope/component/registry.py",
> line 85, in registerUtility self.utilities.register((), provided,
> name, component) File
> "/home/xpmt/.buildout/eggs/zope.interface-3.4.1-py2.4-linux-i686.egg/zope/interface/adapter.py",
> line 117, in register self._v_lookup.add_extendor(provided)
>   File
> "/home/xpmt/.buildout/eggs/zope.interface-3.4.1-py2.4-linux-i686.egg/zope/interface/adapter.py",
> line 430, in add_extendor for i in provided.__iro__:
> AttributeError: type object 'IntIds' has no attribute '__iro__'
> >>>
> ====================
======================================================================


You should probably have "sm.registerUtility(ind, intid.IIntIds)"...
(Note the IIntIds instead of IntIds).

Thierry


More information about the Zope3-users mailing list