Ian Bicking: the old part of his blog


I think there is often a good case for explicitly passing around a context object,
just because it's explicit. I've seen enough problems with acquisition contexts
in Zope 2 to appreciate this -- Zope 2 doesn't hide it perfectly, which means you have to
understand contexts anyway to use it, and the trickery only becomes more voodoo-like ('__of__',
'aq_inner', etc). An explicit context has the important benefit in that it is *simple*.

You can sometimes reduce the amount of context being passed around by making context an
instance variable and centralizing instance construction so that the context is passed
through upon creation. I know that's vague, but it's a pattern I sometimes see.
Comment on Dealing with Context
by Martijn Faassen