Future standard GUI library

Chris Angelico rosuav at gmail.com
Thu Jun 13 10:04:17 EDT 2013


On Thu, Jun 13, 2013 at 7:32 PM, Frank Millman <frank at chagford.com> wrote:
> I am talking about what I call 'field-by-field validation'. Each field could
> have one or more checks to ensure that the input is valid. Some can be done
> on the client (e.g. value must be numeric), others require a round-trip to
> the server (e.g. account number must exist on file). Some applications defer
> the server-side checks until the entire form is submitted, others perform
> the checks in-line. My preference is for the latter.

It's not either-or. The server *MUST* perform the checks at the time
of form submission; the question is whether or not to perform
duplicate checks earlier. This is an absolute rule of anything where
the client is capable of being tampered with, and technically, you
could violate it on a closed system; but it's so easy to migrate from
closed system to diverse system without adding all the appropriate
checks, so just have the checks from the beginning.

In terms of software usability, either is acceptable, but do make sure
the user can continue working with the form even if there's latency
talking to the server - don't force him/her to wait while you check if
the previous field was valid. I know that seems obvious, but
apparently not to everyone, as there are forms out there that violate
this...

ChrisA



More information about the Python-list mailing list