Ticket #5592 (closed Bug: fixed)
Reverse bridge to INonStructuralFolder not being checked correctly
| Reported by: | optilude | Owned by: | optilude |
|---|---|---|---|
| Priority: | major | Milestone: | 2.5.1 |
| Component: | Navigation/Folder listings | Keywords: | |
| Cc: |
Description
On Plone 2.5, a RichDocument shows up as a folder (it becomes a tab if it's in the root, the add menu refers to file and image attachment rather than 'add to folder'). This is because context.is_folderish() is True. This shouldn't be the case, since RD implements INonStructuralFolder.
INonStructuralFolder was converted to a Z3 interface and uses a reverse bridge. This bridge works (RichDocument finds it, and sets it with implements), however, the actual checks for this interface are not working. These checks are in CatalogTool.py the isStructuralFolder() method of @@plone, and is_folderish.py (which is in plone_deprecated).
All of these simply check for INonStructuralFolder.providedBy(context), which apparently returns False when context is implementing the Z2 reverse-bridged interface.
I'm not sure what the correct means of checking is in that case... Unfortunately, this means that non-structural folders no longer work in 2.5 for legacy products. For new products that use the Z3 interface, it should be working still.

Perhaps this is related to #5569