Re: docs unclear re using zope global registry

2011-02-19 Thread Chris McDonough
On Sat, 2011-02-19 at 07:45 +, Chris Withers wrote: > On 19/02/2011 00:25, Iain Duncan wrote: > > Further, in case it's useful, if you do this in your app start up code. > > > > gsm = getGlobalSiteManager() > > config = Configurator( registry=gsm ) > > > > then whenever you use > > > > request.

Re: docs unclear re using zope global registry

2011-02-18 Thread Chris Withers
On 19/02/2011 00:25, Iain Duncan wrote: Further, in case it's useful, if you do this in your app start up code. gsm = getGlobalSiteManager() config = Configurator( registry=gsm ) then whenever you use request.registry you're using the zope global registry, in case you have some special need f

Re: docs unclear re using zope global registry

2011-02-18 Thread Daniel Holth
I think you are correct. -- You received this message because you are subscribed to the Google Groups "pylons-devel" group. To post to this group, send email to pylons-devel@googlegroups.com. To unsubscribe from this group, send email to pylons-devel+unsubscr...@googlegroups.com. For more optio

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
Further, in case it's useful, if you do this in your app start up code. gsm = getGlobalSiteManager() config = Configurator( registry=gsm ) then whenever you use request.registry you're using the zope global registry, in case you have some special need for it to be so. thanks iain -- You rece

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
On Fri, Feb 18, 2011 at 3:44 PM, Daniel Holth wrote: > If you want to use the global ZCA then you should call > Configurator.hook_zca. See > http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html#pyramid.config.Configurator.hook_zca > > Global ZCA means calls to > > zope.component.get

Re: docs unclear re using zope global registry

2011-02-18 Thread Daniel Holth
If you want to use the global ZCA then you should call Configurator.hook_zca. See http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html#pyramid.config.Configurator.hook_zca Global ZCA means calls to zope.component.getUtility(ISomething) instead of request.registry.getUtility(ISomet

Re: docs unclear re using zope global registry

2011-02-18 Thread Iain Duncan
On Fri, Feb 18, 2011 at 6:12 AM, Chris Withers wrote: > On 18/02/2011 04:35, Iain Duncan wrote: > >> And I see the following: >> "If the registry argument is passed as a non-None value, it must be an >> instance of the pyramid.registry.Registry class representing the >> registry to configure." >>

Re: docs unclear re using zope global registry

2011-02-18 Thread Chris Withers
On 18/02/2011 04:35, Iain Duncan wrote: And I see the following: "If the registry argument is passed as a non-None value, it must be an instance of the pyramid.registry.Registry class representing the registry to configure." I certainly hope this isn't true. It would be frustrating if Pyramid n

Re: docs unclear re using zope global registry

2011-02-17 Thread Chris McDonough
Can you help provide the answer? - C On Thu, 2011-02-17 at 20:35 -0800, Iain Duncan wrote: > I was looking at the docs for the pyramid.Configurator object here: > http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html > > And I see the following: > "If the registry argument is passed

docs unclear re using zope global registry

2011-02-17 Thread Iain Duncan
I was looking at the docs for the pyramid.Configurator object here: http://docs.pylonsproject.org/projects/pyramid/dev/api/config.html And I see the following: "If the registry argument is passed as a non-None value, it must be an instance of the pyramid.registry.Registry class representing the re