Re: [Zope3-dev] Re: Can an adapter find out what name it was registered for?
Previously Chris Withers wrote: Really? Certainly in Zope 2, prettymuch every persistent objects needs to be getId()'able... The fact that something is true in Zope 3 does not necessarily make it a good idea. Wichert. -- Wichert Akkerman [EMAIL PROTECTED]It is simple to make things. http://www.wiggy.net/ It is hard to make things simple. ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: Can an adapter find out what name it was registered for?
On Wednesday 29 November 2006 03:37, Wichert Akkerman wrote: The fact that something is true in Zope 3 does not necessarily make it a good idea. But the chances are pretty high! ;-) Regards, Stephan -- Stephan Richter CBU Physics Chemistry (B.S.) / Tufts Physics (Ph.D. student) Web2k - Web Software Design, Development and Training ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: Can an adapter find out what name it was registered for?
Previously Stephan Richter wrote: On Wednesday 29 November 2006 03:37, Wichert Akkerman wrote: The fact that something is true in Zope 3 does not necessarily make it a good idea. But the chances are pretty high! ;-) Of course I meant to say 'Zope 2' there, which does reduce the chances. Wichert. -- Wichert Akkerman [EMAIL PROTECTED]It is simple to make things. http://www.wiggy.net/ It is hard to make things simple. ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] ZCML, functional testing and buildout
On Nov 29, 2006, at 3:01 AM, Christian Theune wrote: Hi, Jim Fulton wrote: I think package-includes or something like an egg basket could be useful for an application, like plone, that wants to support extension by non-developers. But for developers, I think direct zcml includes is better. Ok, I've been starting to transform this in our project to this approach, and for that to work the instance recipe needs to be able to somehow involve the custom ZCML in the instance. You said you didn't like the package-includes, but IIRC you don't like skeletons either. Am I missing something? (I've stripped everything down to a single package-include for now, so it keeps working for us.) My intention, when I have time is to write a new Zope3 instance recipe that takes a single zcml file that defines the application and that doesn't do anything with package-includes or otherwise try to emulate the existing site.zcml. Jim -- Jim Fulton mailto:[EMAIL PROTECTED]Python Powered! CTO (540) 361-1714 http://www.python.org Zope Corporationhttp://www.zope.com http://www.zope.org ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] ZCML, functional testing and buildout
Hi, Jim Fulton wrote: My intention, when I have time is to write a new Zope3 instance recipe that takes a single zcml file that defines the application and that doesn't do anything with package-includes or otherwise try to emulate the existing site.zcml. Ok. Many thanks for the clarification. I'll stop nagging you for now and will try to notice when you're working on a new recipe to get you more questions then. :) Christian -- gocept gmbh co. kg - forsterstraße 29 - 06112 halle/saale - germany www.gocept.com - [EMAIL PROTECTED] - phone +49 345 122 9889 7 - fax +49 345 122 9889 1 - zope and plone consulting and development signature.asc Description: OpenPGP digital signature ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
Re: [Zope3-dev] Re: Can an adapter find out what name it was registered for?
Chris Withers wrote at 2006-11-28 18:09 +: Benji York wrote: Chris Withers wrote: I don't think it'll be a common pattern, but it doesn't feel right to me that a named adapter (ie: one registered with a specific name) has no way of finding out what name it has been registered with... Because the same adapter can be registered more than once, it would actually need to find out all the names with which it was registered. Really? Now this is a use case I hadn't thought of.. can you give me some examples of where you've run into this? An example where an adapter *can* be registered several times was presented by yourself :-) The str adapter (factory) can be used to adapt anything to a string. You may register it several times because you may not want to adapt all interfaces with it but only those derived of several base interfaces. You may or may not use different names as you might have different types of string adaptation (e.g. different types of string presentations). The str example shows also that it is not sensible that the adapter registry framework gives the adapter (factory) a way to determine its name (str has nothing where the name could be sticked in). -- Dieter ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
[Zope3-dev] Grok, CherryPy, WSGI and Zope 3
Hey, I've recently written a few blog entries that may be of interest here too. First an introduction about the Grok project: http://faassen.n--tree.net/blog/view/weblog/2006/11/09/0 Next, what I wrote tonight, which is about my experiments with Grok, Zope 3, WSGI and CherryPy: http://faassen.n--tree.net/blog/view/weblog/2006/11/29/0 I'm very curious to hear what people think about all this. :) Regards, Martijn ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com
[Zope3-dev] provider: adapter doesn't support nocall:?
Hi all, I find that the provider syntax doesn't allow a nocall: specifier. ie: the following tal syntax fails, because regardless of the nocall: modifier, the provider: is rendered at once, and you end up calling render on a string. Is this a bug? div tal:define=obj nocall:provider:q2d-prov tal:content=obj/render/ My intent is to call the update at a separate place from the render. How else might I achieve this? I can only think of explicitly getting the provider in python code, like so vmgr = zope.component.getMultiAdapter( (self.context, self.request, self), IViewletManager, name='q2d-prov') and doing the the update and render separately. Thanks, Roy ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com