Hi, I'm writing a web-app with TurboGears and ToscaWidgets. I encounter a ""The input field 'self' was not expected."" problem.
I fix the problem with the solution I found in http://groups.google.com/group/turbogears/browse_thread/thread/c2a70a9962e08b6e/c8b525ad71fcc6ad?lnk=gst&q=The+input+field+%27self%27+was+not+expected.#c8b525ad71fcc6ad Here is the code I write. from tw.dynforms.widgets import GrowingTableFieldSet from tw.forms.fields import TableForm, TextField, TextArea from tw.forms import validators from formencode.schema import Schema class TGSchema(Schema): filter_extra_fields = True allow_extra_fields = True class WangeaCreateForm(TableForm): validator=TGSchema method='POST' children = [ TextField( name = 'title', label = _('title'), validator = validators.All(validators.NotEmpty(), validators.MaxLength(64)) ), TextArea( name = 'description', label = _('description'), validator = validators.MaxLength(512) ), ] It works, there is no more "The input field 'self' was not expected." error, but....however, I found that the validator does not work. Once I send a empty title, it is directed to error_handle page, but there is no error message in the form. I print kwargs to see what's wrong. {'tg_exceptions': None, 'tg_source': <function process_form at 0x019579B0>, 'description': u'', 'tg_errors': {'title': 'Please enter a value'}, 'title': u''} It seems that TurboGears use tg_errors as key of errors, so ToscaWidgets have no idea about it. Is that correct? How to fix this problem? Thanks. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears?hl=en -~----------~----~----~----~------~----~------~--~---

