Path: csiph.com!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.032 X-Spam-Evidence: '*H*': 0.94; '*S*': 0.00; 'duplicate': 0.07; 'preference': 0.07; 'system;': 0.09; 'usability,': 0.09; '*must*': 0.16; 'defer': 0.16; 'earlier.': 0.16; 'file).': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'subject:GUI': 0.16; 'subject:library': 0.16; 'valid.': 0.16; 'appropriate': 0.16; 'wrote:': 0.18; 'everyone,': 0.19; 'thu,': 0.19; 'seems': 0.21; 'input': 0.22; 'diverse': 0.24; 'question': 0.24; 'header:In-Reply-To:1': 0.27; 'absolute': 0.30; 'message- id:@mail.gmail.com': 0.30; "skip:' 10": 0.31; '13,': 0.31; 'apparently': 0.31; 'with,': 0.31; '(e.g.': 0.33; 'could': 0.34; 'but': 0.35; 'received:google.com': 0.35; 'there': 0.35; 'done': 0.36; 'being': 0.38; 'server': 0.38; 'checks': 0.38; 'to:addr :python-list': 0.38; 'pm,': 0.38; 'previous': 0.38; 'anything': 0.39; 'sure': 0.39; 'to:addr:python.org': 0.39; 'either': 0.39; 'ensure': 0.60; 'even': 0.60; 'easy': 0.60; 'entire': 0.61; 'field': 0.63; 'more': 0.64; 'account': 0.65; 'talking': 0.65; 'capable': 0.67; 'frank': 0.68; 'this...': 0.84; 'obvious,': 0.91; '2013': 0.98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=MGHQuULo4LkqB7bntlKC3hjX/wwUtVKDvK030bje+1I=; b=Opir3KpjLkWa9FBll0W5GwpTsAtiACdTLUD5T8LinLkNOYRtIODLdzWE1k6vKK50hq +2RnSHV65kn71yKqFSDYhyrVY2GPKBiTj1m3mtJszprkpTW0zQ0vFd/gwMc6L0+gDO2/ GxR5ArGhWYEPVYEoz9CCA6jT9vbsqghtpgicZr/nK1cx2CubaaV4nJXIIYm9LS0MUD2M 1s96rg9kOumLocz4o4SJJ+2kU1zyufV66IsnIaCHzvSMsVt4zT25Ju0ZINlB19NOHxfx AiyTAlpyBkoQ+AdblcdzmOqpz9JbacU1GCBgNgpIdNFPuSSG3OwkoS+p5qTOSIk/Q+4x 37Nw== MIME-Version: 1.0 X-Received: by 10.58.214.105 with SMTP id nz9mr348116vec.58.1371132257268; Thu, 13 Jun 2013 07:04:17 -0700 (PDT) In-Reply-To: References: <20130522154233.fe5263cb231c375fc60c7c9b@gmx.net> <20130523174145.22a6c46f586b0a1f656d2412@gmx.net> <20130526194310.9cdb1be80b42c7fdf0ba502f@gmx.net> <20130527172250.a8b0ce44f29398d63a4ec650@gmx.net> <20130530184045.6d15530be70e18d96e5654ad@gmx.net> <20130601201817.55d3361dda93dac387a9eab6@gmx.net> <20130612222819.2a044e86ab4b6defe1939a04@gmx.net> Date: Fri, 14 Jun 2013 00:04:17 +1000 Subject: Re: Future standard GUI library From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 24 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1371132261 news.xs4all.nl 16007 [2001:888:2000:d::a6]:35230 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:47965 On Thu, Jun 13, 2013 at 7:32 PM, Frank Millman 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