Fred Drake wrote:
> [...]
> You probably want to check the results of the edit widgets; they might
> produce list values instead of PersistentList values.  Widgets are not
> expected to edit the value in place, but to produce a new value.

They seem to do the right thing (I fixed one of the cases when it didn't).
Check zope/app/form/browser/

(Link to file on svn: )

        # All AbstractCollection fields have a `_type` attribute specifying
        # the type of collection. Use it to generate the correct type,
        # otherwise return a list.  TODO: this breaks encapsulation.
        if hasattr(self.context, '_type'):
            _type = self.context._type
            if isinstance(_type, tuple):
                _type = _type[0]
            return _type(values)
            return values

View this message in context:
Sent from the Zope3 - users mailing list archive at

Zope3-users mailing list

Reply via email to