[Zope-CMF] DynamicType's __before_publishing_traverse__

Chris McDonough chrism at plope.com
Thu Mar 4 21:22:16 EST 2004


Some time ago (maybe 8 months ago or so.. wow, I'm so out of the loop),
Yuppie changed DynamicType to have a __before_publishing_traverse__
method that munges the request's path to set the default view for the

This code in PortalContent still exists, but I can't think of a case
where it ever gets invoked:

   def __call__(self):
        Invokes the default view.
        view = _getViewFor(self)
        if getattr(aq_base(view), 'isDocTemp', 0):
            return view(self, self.REQUEST)
            return view()

    index_html = None  # This special value informs ZPublisher to use

It is sort of misleading to leave this code around, I think.  Can anyone
think of a case where it gets used anymore?  If so, then why have the
__before_publishing_traverse__ too?

- C

More information about the Zope-CMF mailing list