-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 10/13/2014 09:54 PM, Chris Rossi wrote:
> My naive first take is just write a utility method:
> 
> def find_sitemanager(context): """ Find nearest site manager, walking
> back up the tree from 'context'. """
> 
> Then, don't use the global API, but call getUtility and queryUtility
> on the local registry that you find with your utility method.

(Totally untested) You could subscribe to the IContextFound event, and
set the sitemanager based on context from within it:  the global APIs
would "Just Work" at that point.


Tres.
- -- 
===================================================================
Tres Seaver          +1 540-429-0999          [email protected]
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)

iEYEARECAAYFAlQ8iZEACgkQ+gerLs4ltQ5T1gCgpQ5OmVSbPJLt75WaMkxC45sR
ZSkAmwU7VGul/AopE0pGQYU3LQsQ2tAG
=xS7M
-----END PGP SIGNATURE-----

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pylons-discuss.
For more options, visit https://groups.google.com/d/optout.

Reply via email to