<html>
    <head />
        <body>
            Ok, here's the relevant code:<br /><br />class IFooField(interface.Interface):<br />&nbsp;&nbsp;&nbsp; name = schema.TextLine(title=u'Name', required = True)<br />&nbsp;&nbsp;&nbsp; label = schema.TextLine(title=u'Label', required = True)<br />&nbsp;&nbsp;&nbsp; format = schema.Choice(title=u'Field Format', required = True, values = ['Text', 'Date', 'Number'])<br /><br />class IFoo(interface.Interface):<br />&nbsp;&nbsp;&nbsp; title=schema.TextLine(title=u'Title',required=True)<br />&nbsp;&nbsp;&nbsp; description=schema.TextLine(title=u'Description',required=False)<br />&nbsp;&nbsp;&nbsp; data_fields_ext = schema.List(title=u'Fields', required = False, unique = True, constraint = check_df,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; value_type = schema.Object(title=u'Field', required = False, schema = IFooField))<br />&nbsp;&nbsp;&nbsp; <br />class Foo(grok.Application, grok.Container):<br />&nbsp;&nbsp;&nbsp; grok.implements(IFoo)<br />&nbsp;&nbsp;&nbsp; title = u'Foobar'<br />&nbsp;&nbsp;&nbsp; description = u''<br />&nbsp;&nbsp;&nbsp; data_fields_ext = None<br /><br />class FooEditForm(grok.EditForm):<br />&nbsp;&nbsp;&nbsp; grok.context(Foo)<br />&nbsp;&nbsp;&nbsp; grok.name('admin')<br />&nbsp;&nbsp;&nbsp; <br />&nbsp;&nbsp;&nbsp; form_fields = grok.AutoFields(Foo) <br />&nbsp;&nbsp;&nbsp; object_widget = CustomWidgetFactory(ObjectWidget, FooField)<br />&nbsp;&nbsp;&nbsp; form_fields['data_fields_ext'].custom_widget = CustomWidgetFactory(SequenceWidget, subwidget=object_widget)<br />&nbsp;&nbsp;&nbsp; template = grok.PageTemplateFile('custom_edit_form.pt')<br /><br />The widgets render fine, but if I click the Apply button, I get the following:<br />
            <div class="form-status">
            <div><br />There were errors</div>
            <ul class="errors">
                <li>              Fields: <span class="error">Object is of wrong type.</span></li>
            </ul>
            I am not sure how I can debug this. I would really appreciate any further advice.<br /><br />Regards,<br />Sascha       </div>
        <div class="signature"><br /><br /><br />-- <br />GMX DSL: Internet-, Telefon- und Handy-Flat ab 19,99 EUR/mtl.  <br />Bis zu 150 EUR Startguthaben inklusive! http://portal.gmx.net/de/go/dsl</div></body>
    </html>