There's currently a funny inconsistency in Zope's Traversable class. If 
you have a URL like http://localhost:8080/path/to/@@aview/foo, and 
@@aview implements IPublishTraverse (and, I presume, if there's a custom 
IPublishTraverse adapter for any other path component), URL traversal 
will work fine, but calling to.restrictedTraverse('@@aview/foo') or some 
variant thereof will fail, because (un)restrictedTraverse() does not 
respect custom IPublishTraverse adapters.

I can kind of see why it's done like this since it's called 
I*Publish*Traverse, but it is a pain.

Note that namespace traversal (like ++skin++) works fine with 

I don't think it'd be hard to implement this, but:

  - is this a bug?
  - is there a reason not to do this?


Author of `Professional Plone Development`, a book for developers who
want to work with Plone. See http://martinaspeli.net/plone-book

Zope-Dev maillist  -  Zope-Dev@zope.org
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope )

Reply via email to