[z3-five] SVN: Products.Five/branches/1.4/ Backported the traversal order changes from zope 2.10

yuppie y.2006_ at wcm-solutions.de
Wed Jul 26 21:48:18 CEST 2006


Hi Alec!


Alec Mitchell wrote:
> On 7/25/06, yuppie <y.2006_ at wcm-solutions.de> wrote:
>> Alec Mitchell wrote:
>>> Log message for revision 69121:
>>>   Backported the traversal order changes from zope 2.10
>> There's a bug in that change. HEAD requests (and I guess also other
>> FTP/WebDAV requests) trigger this error:
>>
>> ERROR Zope.SiteErrorLog http://www.example.org/mySite/virtual_hosting//
>> Traceback (innermost last):
>>    Module ZPublisher.Publish, line 106, in publish
>>    Module ZPublisher.BaseRequest, line 325, in traverse
>>    Module webdav.NullResource, line 66, in __bobo_traverse__
>> NotFound: The requested resource was not found.
>>
>> The VirtualHostMonster adds 'virtual_hosting//' to the URL (don't ask me
>> why). 'virtual_hosting' has to be acquired, but now a NullResource is
>> created instead.
> 
> Hm, this is a bit puzzling.  The code should use acquisition if
> there's no available view and if the attribute is not available via
> item lookup.  Perhaps the context[attr] lookup is returning a
> NullResource?

Don't know. I did no further debugging. All I know is that reverting 
your change fixes this issue. It already took me some time to find that out.

> If this is the case, doesn't the same problem exist in
> Zope 2.10?

Zope 2.10 has the same issue but produces a different traceback:

ERROR Zope.SiteErrorLog http://www.example.org/mySite/virtual_hosting//
Traceback (innermost last):
   Module ZPublisher.Publish, line 106, in publish
   Module ZPublisher.BaseRequest, line 463, in traverse
   Module ZPublisher.BaseRequest, line 318, in traverseName
   Module ZPublisher.BaseRequest, line 114, in publishTraverse
NotFound: The requested resource was not found.

> Is this true for any HEAD request that includes an
> acquired attribute, or just those that go through the VHM?

Same problem with other acquired attributes. This is the Zope 2.10 error:

ERROR Zope.SiteErrorLog http://localhost:8080/mySite/foo/HEAD
Traceback (innermost last):
   Module ZPublisher.Publish, line 115, in publish
   Module ZPublisher.mapply, line 88, in mapply
   Module ZPublisher.Publish, line 41, in call_object
   Module webdav.NullResource, line 74, in HEAD
NotFound: The requested resource does not exist.


BTW: I used wget for testing this, --spider triggers a HEAD request.

wget --spider 
localhost:8080/VirtualHostBase/http/www.example.org:80/mySite/VirtualHostRoot/


Cheers,

	Yuppie



More information about the z3-five mailing list