______________________________________________________________________
Le mardi 14 septembre,
  Jonah Crawford <[email protected]> a écrit :

> I have a situation intids are not resolving back to the objects
> they're paired to:
> 
> using  -->  return getUtility(IIntIds).getObject(intid)
> 
> I get the following trace:
> 
> #id   1683701620
> #self <zope.intid.IntIds object at 0x3632130>
> #
> #>>  return self.refs[id]()
> #TypeError: 'NamedGroup' object is not callable
> 
> I've read the IntIds class and double checked that its zcml
> implements IKeyReference.
> 
> In fact here is the zcml 
> 
> <class class=".channel.Channel">
>   <implements
>      interface="zope.annotation.interfaces.IAttributeAnnotatable"
>      />
>   <implements
>      interface="zope.container.interfaces.IContainer" 
>      />
>   <implements
>      interface="zope.keyreference.interfaces.IKeyReference"
>      />
>   <implements
>      interface="zope.keyreference.interfaces.IKeyReference"
>      />
> 
> I can access the utility and see the intid, reference pairs but any
> thoughts on what will make it resolve ? 
> 
> Are there any other implements I need in the zcml to make this work ?
______________________________________________________________________


Could you be more explicit about your "situation" ?

I thing you also have to include zope.app.keyreference ZCML file.
But I'm not sure at all if it is what's missing in your use case...

Regards,
Thierry
_______________________________________________
bluebream mailing list
[email protected]
https://mail.zope.org/mailman/listinfo/bluebream

Reply via email to