Hello Mike, On Mon, Jan 17, 2011 at 11:23 AM, Mike Orr <sluggos...@gmail.com> wrote:
> So this email is to > collect feedback for that: what are people using, and what do they > think makes sense for Pyramid. > I'm still using formencode for validation/conversion. I use a custom class that encapsulates the minimum functionality necessary for validation use cases(http://packages.python.org/formprocess/). I use htmlfill to fill the forms. I write some html and some mako helper functions to create the form html. In web forms I use one method to display the form, one method to process the form and I have a shared method which renders the form for both cases(initial display and processing errors display). I have not had many problems with this pattern except the obvious warts in formencode which are slim documentation, odd conventions and seemingly unnecessary features. I have no experience with internationalization. I haven't switched to pyramid yet but I would expect that I would just keep using the same tools and patterns. I am interested in new solutions though and believe one day a tiered solution could be developed to finally solve this problem for almost everyone. Which brings us to Formish and Deform. At first glance, Formish seems > to be a streamlining of FormEncode into discrete classes for schemas, > validation, type conversion (which it separates from validation), with > specific support for nested form data and file uploads. It also adds a > layer for form generation using Mako. Deform, by our own ChrisM, is a > reimplementation of the Formish concept using different libraries and > Chameleon templates. > Maybe a feature/library matrix could be compiled somewhere to compare all these libraries and test their support of certain features? I could help with that if you think that would be helpful. > Another issue is one-view vs two-view form processing. The tradtional > way (before I came to Pylons) was to use one view with an 'if' that > would display the form if there are no POST variables, or validate it > if there are, and an inner 'if' to do the action if the validation > succeeds, or to redisplay the form with errors if it fails. > It might be important to differentiate between one/two urls and one/two views since any combination of these could occur: * There could be one url with two views(views matching on the method -- one for GET and one for POST). * There could be one url with one view(handles both GET and POST with conditional) * There could be two urls with two views(one for GET and one for POST). * There could be two urls with one view (view handles both GET and POST with conditional) -Ian -- You received this message because you are subscribed to the Google Groups "pylons-devel" group. To post to this group, send email to pylons-devel@googlegroups.com. To unsubscribe from this group, send email to pylons-devel+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/pylons-devel?hl=en.