[Zope-dev] Re: View component registration

2008-06-20 Thread Martijn Faassen
Hey, Jim Fulton wrote: [snip] I suggest: - decide on and advertise the new interface - continue to do look ups the way we do now - update relevant zcml directives (view, page, resource. etc.) to use the new interface +1 Update the relevant grokkers to use the new interface too. :)

[Zope-dev] Re: View component registration

2008-06-20 Thread Martijn Faassen
Hey, One question is what to do for persistent registrations in local sites. I don't imagine they're used a lot, but it'd mean a content upgrade to re-register them, right? Regards, Martijn ___ Zope-Dev maillist - Zope-Dev@zope.org

[Zope-dev] Re: View component registration

2008-06-20 Thread Philipp von Weitershausen
Martijn Faassen wrote: One question is what to do for persistent registrations in local sites. I don't imagine they're used a lot, but it'd mean a content upgrade to re-register them, right? The only piece of software that, to my knowledge, can actually *make* local view registrations is

[Zope-dev] Re: View component registration

2008-06-19 Thread Martijn Faassen
Malthe Borch wrote: Martijn Faassen wrote: There's one major problem that I see. What's the backwards compatibility story? I'm sure there are a lot of cases in lots of code where people look up views with a getMultiAdapter, and if we started registering views differently, wouldn't that code

[Zope-dev] Re: View component registration

2008-06-19 Thread Philipp von Weitershausen
David Glick wrote: On Jun 18, 2008, at 1:44 PM, Malthe Borch wrote: Martijn Faassen wrote: There's one major problem that I see. What's the backwards compatibility story? I'm sure there are a lot of cases in lots of code where people look up views with a getMultiAdapter, and if we started

Re: [Zope-dev] Re: View component registration

2008-06-19 Thread Jim Fulton
On Jun 19, 2008, at 9:37 AM, Philipp von Weitershausen wrote: David Glick wrote: On Jun 18, 2008, at 1:44 PM, Malthe Borch wrote: Martijn Faassen wrote: There's one major problem that I see. What's the backwards compatibility story? I'm sure there are a lot of cases in lots of code where

Re: [Zope-dev] Re: View component registration

2008-06-19 Thread Christian Theune
On Thu, Jun 19, 2008 at 09:46:35AM -0400, Jim Fulton wrote: I suggest: - decide on and advertise the new interface - continue to do look ups the way we do now - update relevant zcml directives (view, page, resource. etc.) to use the new interface - issue informative deprecation

Re: [Zope-dev] Re: View component registration

2008-06-19 Thread Jim Fulton
On Jun 19, 2008, at 10:46 AM, Christian Theune wrote: On Thu, Jun 19, 2008 at 09:46:35AM -0400, Jim Fulton wrote: I suggest: - decide on and advertise the new interface - continue to do look ups the way we do now - update relevant zcml directives (view, page, resource. etc.) to use the new

Re: [Zope-dev] Re: View component registration

2008-06-19 Thread Christian Theune
On Thu, Jun 19, 2008 at 10:50:00AM -0400, Jim Fulton wrote: Would it be reasonable to also issue a warning if someone does a lookup for Interface? No, because clients have to look up using Interface as long as the component they need might be registered with it. Is that an argument for

Re: [Zope-dev] Re: View component registration

2008-06-19 Thread Jim Fulton
On Jun 19, 2008, at 10:53 AM, Christian Theune wrote: On Thu, Jun 19, 2008 at 10:50:00AM -0400, Jim Fulton wrote: Would it be reasonable to also issue a warning if someone does a lookup for Interface? No, because clients have to look up using Interface as long as the component they need

[Zope-dev] Re: View component registration

2008-06-18 Thread Martijn Faassen
Hi there, Malthe Borch wrote: [snip] I suggest we then register views as components providing ``zope.component.IView``; browser views should provide ``zope.publisher.interfaces.browser.IBrowserView``. I think this would improve things, and thanks for bringing this up. There's one major

[Zope-dev] Re: View component registration

2008-06-18 Thread Malthe Borch
Martijn Faassen wrote: There's one major problem that I see. What's the backwards compatibility story? I'm sure there are a lot of cases in lots of code where people look up views with a getMultiAdapter, and if we started registering views differently, wouldn't that code break? How to we get

Re: [Zope-dev] Re: View component registration

2008-06-18 Thread David Glick
On Jun 18, 2008, at 1:44 PM, Malthe Borch wrote: Martijn Faassen wrote: There's one major problem that I see. What's the backwards compatibility story? I'm sure there are a lot of cases in lots of code where people look up views with a getMultiAdapter, and if we started registering views

[Zope-dev] Re: View component registration

2008-06-18 Thread Malthe Borch
Christian Theune wrote: I don't think zope.component wants to know about views. The interface should be in a package that already knows about views. I agree it's an inappropriate location, however, zope.component *does* define an ``IView`` interface as it is (zope.component.bbb.interfaces).

[Zope-dev] Re: View component registration

2008-06-18 Thread Philipp von Weitershausen
Jim Fulton wrote: On Jun 18, 2008, at 4:31 PM, Malthe Borch wrote: Currently views are registered as components providing zope.interface.Interface; this is unfortunate since other kinds of components may use the same specification, namely (context, request). Right. This is a historical

[Zope-dev] Re: View component registration

2008-06-18 Thread Philipp von Weitershausen
Malthe Borch wrote: Currently views are registered as components providing zope.interface.Interface; this is unfortunate since other kinds of components may use the same specification, namely (context, request). An example of this is ``IAbsoluteURL``; it clashes with the resources view*.