Re: Non-ZCML config for ZCA. (Was: Anyone want to do Google Summer of code mentoring for PSF?)

Jim Fulton <[email protected]>
Newsgroups gmane.comp.web.zope.devel
Message-ID <[email protected]>
On Mon, Mar 21, 2011 at 10:07 AM, Lennart Regebro <[email protected]> wrote:
> On Mon, Mar 21, 2011 at 14:17, Martijn Faassen <[email protected]> wrote:
...
> With martian, the registration is then done by the grokking process,
> but I think decorators would be a process that is more acceptable to
> the Python world in general. Instances does indeed require something
> else than decorators, I hadn't thought of that, that's a drawback.

I think Martijn raised a good question about the conceptual
interaction of class decorators and inheritance.  (Arguablly the
questions applies to the "advice"-based syntax as well.) If I see:

@some_decorator
class Base:
     ....

class Sub(Base):
     ...

I'm going to wonder how the decorator affects Sub. (Wondering is work. :)

This might be OK for @implements and maybe @adapts, which describe
behavior, but start feeling wonky to me for something like: @utility.
Maybe it's enough to document what the directives do.  Or maybe
something less attached to the class definition would make sense.

I don't know what the right answer is ... at least not yet. :)

Jim

-- 
Jim Fulton
http://www.linkedin.com/in/jimfulton
_______________________________________________
Zope-Dev maillist  -  [email protected]
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.