Please help with failing tests that block 5.2 final release

We need help to fix a couple of failing tests in the Python 2.7 build related to WebDAV. See

Zope 4.0 final was released this Friday as planned. Excellent!!! We had planned to release Plone 5.2 final as pending this weekend and do the official release of Plone 5.2 on May 20 (see Plone 5.2 Release Team Meeting, April 28, 2019). But unless we fix these issues we need to postpone the release. I myself was ill last week, am only now recovering and have very little time for this this week.

@Rotonen has already fixed those WebDAV issues, but was still checking if it is correct that plone.rfc822 gets bytes on 2.7, but strings on 3.7... or is there still something else.

Great to hear! I rebased and started the jobs. Let's see it that fixes everything.

Oh, sorry. They are not yet merged.

I merged these two, rebased and restarted the jobs.

There are still 6 test-failures:



All but test_createObject (in Products.ATContentTypes.tests.test_atnewsitem.TestATNewsItemFunctional) are fixed by
The last one probably fails on the space in "News Item" but is also caused by something in

I'm still looking...

Found it. It was a different commit:

The problem is that the location is changed from

http://nohost/plone/Members/test_user_1_/portal_factory/News Item/news_item.2019-05-13.5570404352/



which results in a 404.

I'm now officially out of time until Thursday. Please someone take this over so we don't have to postopone the release even further!

Sooo. The last problem (TestATNewsItemFunctional) is not real-life issue since adding Archetypes News Items works fine with and without the modified response in the redirect. I spent most of today trying to find the cause and first had a couple of fistfights with CMFFormController (please die already!) and the Controller Python Script createObject.cpy which is used in that test. Turns out that was not the issue.

The issue is actually really the space in "News Item". Since the url gets url-quoted. That turns News Item to News%20Item

During ZPublisher.BaseRequest.BaseRequest.traverse the step News%20Item is then quoted again, resulting in News%2520Item.

Then when Plone tries to traverse from portal_factory to News%20Item the item is not found:

(Pdb++) self.traverseName(object, 'News%20Item')
*** AttributeError: News%20Item

(Pdb++) self.traverseName(object, 'News%2520Item')
*** AttributeError: News%2520Item

(Pdb++) self.traverseName(object, 'News Item')
<TempFolder at /plone/Members/test_user_1_/portal_factory/News Item>

The same happens when using unrestrictedTraverse.

That finally led me down to Products.ATContentTypes.tool.factory.FactoryTool.__bobo_traverse__. That's a rather simple method that returns a temporary folder to hold the new item during creation but the %20 prevente it from finding the type.

Fixed in

I learned again:

  1. Disable handle_errors in functional tests.
  2. If you persist and do not hurry you might eventually find the issue.
  3. Expect custom publishTraverse and __bobo_traverse__ methods in all kinds of places. Expect bug in them to be swallowed.

It'd not be the worst idea to unify and clean up all the publish and traversal side magic as encountered. Sounds Plone 6 worthy.