launchpad-dev team mailing list archive
-
launchpad-dev team
-
Mailing list archive
-
Message #04613
Re: Need some help to understand weirdness with the propertycache API
On Mon, 2010-09-13 at 17:16 +0100, Jonathan Lange wrote:
> On Fri, Sep 10, 2010 at 12:41 PM, Gavin Panella
> <gavin.panella@xxxxxxxxxxxxx> wrote:
> ...
> > It already seems weird to register them both via ZCML and the global
> > site manager. If I just use ZCML a whole raft of tests fail. If I just
> > use ZCML a different raft of tests fails.
> >
>
> I just spent a few minutes trying to figure this out, but nothing
> leapt to mind. There being only two classes that won't adapt makes me
> suspicious.
>
> Were I you, I'd find some way to trick Zope into using the Python
> version of z.interface and step through InterfaceBasePy.__call__ for
> one of those failing tests.
>
> Use ZCML, not gsm. Relying on Python import order is bad for ones
Couldn't agree more here, but if for any reason you can't use ZCML (e.g.
you want to have your adapters' names in python), then you can use
<call callable="..." />
in ZCML to call your python code that does the actual registration.
> health. Remember that different layers load different sets of ZCML.
--
Guilherme Salgado <https://launchpad.net/~salgado>
Attachment:
signature.asc
Description: This is a digitally signed message part
References