I have a componentized form that is behaving very strangely. The form
is very simple -- just a text field.
form=SQLFORM.factory(Field('text_in','text'))
if form.accepts(request.vars, session):
.... do stuff ...
The first time I load the form, it loads fine. I traced it in Eclipse
and saw the form getting created with SQLFORM.factory. When I fill in
text, however, the form does not accept, nor does it generate any
error. Inspecting in Eclipse shows form.vars is empty.
OK, so now the form is still visible since it was reloaded. I enter
the same text again and click submit. This time, the form.accepts(...)
accepts the form and processes it.
I upgraded to the latest and greatest version but still get this
strange behavior. Anybody have an idea what's going on?