[Zope-dev] Zope Tests: 8 OK
Summary of messages to the zope-tests list. Period Sat Oct 3 12:00:00 2009 UTC to Sun Oct 4 12:00:00 2009 UTC. There were 8 messages: 8 from Zope Tests. Tests passed OK --- Subject: OK : Zope-2.10 Python-2.4.6 : Linux From: Zope Tests Date: Sat Oct 3 20:45:37 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012696.html Subject: OK : Zope-2.11 Python-2.4.6 : Linux From: Zope Tests Date: Sat Oct 3 20:47:37 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012697.html Subject: OK : Zope-2.12 Python-2.4.6 : Linux From: Zope Tests Date: Sat Oct 3 20:49:37 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012698.html Subject: OK : Zope-2.12-alltests Python-2.4.6 : Linux From: Zope Tests Date: Sat Oct 3 20:51:37 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012699.html Subject: OK : Zope-2.12 Python-2.6.2 : Linux From: Zope Tests Date: Sat Oct 3 20:53:37 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012700.html Subject: OK : Zope-2.12-alltests Python-2.6.2 : Linux From: Zope Tests Date: Sat Oct 3 20:55:38 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012701.html Subject: OK : Zope-trunk Python-2.6.2 : Linux From: Zope Tests Date: Sat Oct 3 20:57:38 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012702.html Subject: OK : Zope-trunk-alltests Python-2.6.2 : Linux From: Zope Tests Date: Sat Oct 3 20:59:38 EDT 2009 URL: http://mail.zope.org/pipermail/zope-tests/2009-October/012703.html ___ Zope-Dev maillist - Zope-Dev@zope.org https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Zope 2, WebDAV and browser-default
Hi, I came across this trying to implement WebDAV support for some content in Zope 2. The ZPublisher will always traverse to the return value from 'browserDefault()' (either from a custom IBrowserPublisher adapter, or the DefaultPublishTraverse object hardcoded in ZPublisher.BaseRequest) when it gets to the end of a traversal chain, even for WebDAV requests. This makes it impossible to e.g. get a folder listing in WebDAV. The default 'browserDefault()' will call __browser_default__() on the context if that exists. If not, it will call queryDefaultView(), which returns a view name as set by a browser:defaultView / directive, and return that name unless it is None. The publisher will then traverse to the name indicated. This breaks WebDAV in two ways: Consider a folder /foo/bar. The class for 'bar' does not implement __browser_default__(), but there is a default view, set with the browser:defaultView / directive, called 'index'. Let's say the WebDAV client attempts to do a PROPFIND request to list the folder's contents. The publisher will traverse to /foo/bar and then look up the default view, @@index, and attempt to traverse to that. This doesn't have the PROPFIND() verb method, obviously, since views don't derive from webdav.Resource, and so the WebDAV requests fails. Even if it does, there's some code at the end of BaseRequest.traverse() which checks that the last item in the traversal chain is *not* acquired (i.e. it's a genuine child of the aq_base'd second-to-last item). This is to allow PUT'ing to a name that could've been acquired (via the NullResource mechanism). This means that if you have registered a browser:defaultView / for an object, it is impossible for that object to participate in WebDAV requests. We never noticed in Plone before, because most Plone content implements __browser_default__ so that it delegates to PloneTool.browserDefault() which aborts immediately if it detects a WebDAV request. The default behaviour does *not* do this, however, and it seems wrong to expect everyone who implements __browser_default__ or an IBrowserPublisher adapter to have to do so. My suggestion would be that we simply skip the browserDefault() lookup for WebDAV requests. I don't think it's meaningful to have a browser-default page when looking at objects via WebDAV at all. I can make the change as a bugfix to 2.10, 2.11 and 2.12 if no-one objects. Martin ___ Zope-Dev maillist - Zope-Dev@zope.org https://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope )
Re: [Zope] [Zope-Annce] ZClasses resurrected
So...we are on 2.8.10 and our biggest app on our site is a ZClass based news object. How close will this provide functionality to just drop our data.fs into 2.12 and have those zclasses work? This is huge news! Thanks Dieter -Allen Dieter Maurer wrote: The Zope developers have ripped out the ZClasses functionality from the Zope core in version 2.12. As promised, I have collected the former code in a new package (dm.zopepatches.zclasses on PyPI). When imported, this package uses monkey patching to restore the ZClasses functionality. New tests verify the functionality as formerly described in the Zope book (2.7 edition). To make ZClasses available again, the ZODB root database requires dm.zopepatches.zclasses.ClassFactory as class-factory option in the Zope configuration file. When this option is processed, the package is imported and the monkey patching takes place. The current version does not yet restore the distribution functionality (of Zope products). Let me know when you need this functionality. ___ Zope maillist - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] [Zope-Annce] ZClasses resurrected
Allen Schmidt Sr. wrote at 2009-10-4 16:40 -0400: So...we are on 2.8.10 and our biggest app on our site is a ZClass based news object. How close will this provide functionality to just drop our data.fs into 2.12 and have those zclasses work? I do not know. ZClasses have quite vast functionality. My test, however, only covers that part documented in the former (2.7 edition) Zope book. Your ZClasses usage may use much more and there may still be problems therein. I tried to move on old Data.fs (from a Zope 2.8.1 on Python 2.4 with the ZClass created even earlier) to the new Zope (2.12.0 on Python 2.6) and got a ZODB problem (an AccessControl.Permission.PermissionMapping.PM could not be loaded). PermissionMapping.PM is used by ZClasses (to map general Zope permissions to ZClass specific permissions) but the problem seems not be directly related to the ZClasses code. Instead, it looks like a Python (pickle/cPickle) bug I have encountered earlier when an object was pickled when it still was an instance of an old style Python class and should now be unpickled as an instance of a new style class. This fails because old style class pickling uses an optimization not recognized for new style classes. Because nothing changed between Zope 2.8 and Zope 2.12 with respect to the PermissionMapping.PM class type, I expect that the problem was already in the Zope 2.8 instance but the ZODB 3.4 (part of Zope 2.8) was less picky with respect to broken objects than the ZODB 3.9 used by Zope 2.12. I could successfully move a Data.fs with a ZClass created under Zope 2.11 to Zope 2.12. Thus, no garantee that you will not face problems. Try it out and report back. I am ready to sort out ZClasses related problems -- with the active help of people who observe such problems. -- Dieter ___ Zope maillist - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] [Zope-Annce] ZClasses resurrected
this is great, I never used ZClasses. But I really cherish that somebody did speak up and keeps on giving suport to parts of the zope ecosystem the rest of the community stopped to maintain. robert Dieter Maurer wrote: The Zope developers have ripped out the ZClasses functionality from the Zope core in version 2.12. As promised, I have collected the former code in a new package (dm.zopepatches.zclasses on PyPI). When imported, this package uses monkey patching to restore the ZClasses functionality. New tests verify the functionality as formerly described in the Zope book (2.7 edition). To make ZClasses available again, the ZODB root database requires dm.zopepatches.zclasses.ClassFactory as class-factory option in the Zope configuration file. When this option is processed, the package is imported and the monkey patching takes place. The current version does not yet restore the distribution functionality (of Zope products). Let me know when you need this functionality. ___ Zope maillist - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope-dev ) ___ Zope maillist - Zope@zope.org https://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - https://mail.zope.org/mailman/listinfo/zope-announce https://mail.zope.org/mailman/listinfo/zope-dev )