[web2py] Re: CLEANUP() removing too many characters

2011-05-01 Thread Massimo Di Pierro
I do not have a strong opinion. I can make it accept tab. Uploading to trunk. On May 1, 8:57 am, Jonathan Lundell wrote: > On Apr 30, 2011, at 11:13 PM, Massimo Di Pierro wrote: > > > > > I am not convinced about tab. I hate tab, it only causes problems. > > In Python it does, but it solves probl

Re: [web2py] Re: CLEANUP() removing too many characters

2011-05-01 Thread Jonathan Lundell
On Apr 30, 2011, at 11:13 PM, Massimo Di Pierro wrote: > > I am not convinced about tab. I hate tab, it only causes problems. In Python it does, but it solves problems elsewhere. I don't know what the expected use case is for CLEANUP; I don't see it used anywhere in the web2py apps. It might a

[web2py] Re: CLEANUP() removing too many characters

2011-05-01 Thread pbreit
I guess one question is what is the point. It's very similar to the regex [:print:] which apparently in PERL includes [:space:] which includes \t. I was actually using it to strip out tabs but I ended up going with a custom validator. http://en.wikipedia.org/wiki/Regular_expression

[web2py] Re: CLEANUP() removing too many characters

2011-04-30 Thread Massimo Di Pierro
I am not convinced about tab. I hate tab, it only causes problems. On May 1, 12:29 am, Jonathan Lundell wrote: > On Apr 25, 2011, at 7:46 PM, Massimo Di Pierro wrote: > > > > > I agree. > > Perhaps tab should be retained as well. > > > > > > > > > > > On Apr 25, 8:59 pm, Jonathan Lundell wrote:

Re: [web2py] Re: CLEANUP() removing too many characters

2011-04-30 Thread Jonathan Lundell
On Apr 25, 2011, at 7:46 PM, Massimo Di Pierro wrote: > > I agree. Perhaps tab should be retained as well. > > On Apr 25, 8:59 pm, Jonathan Lundell wrote: >> On Apr 25, 2011, at 6:49 PM, Massimo Di Pierro wrote: >> >> >> >>> True. It should do what the book says. >> >> Except that we shoul

[web2py] Re: CLEANUP() removing too many characters

2011-04-25 Thread Massimo Di Pierro
I agree. On Apr 25, 8:59 pm, Jonathan Lundell wrote: > On Apr 25, 2011, at 6:49 PM, Massimo Di Pierro wrote: > > > > > True. It should do what the book says. > > Except that we should probably change the definition to exclude 127, seems to > me. > > > > > > > > > > > On Apr 25, 6:43 pm, pbreit

Re: [web2py] Re: CLEANUP() removing too many characters

2011-04-25 Thread Jonathan Lundell
On Apr 25, 2011, at 6:49 PM, Massimo Di Pierro wrote: > > True. It should do what the book says. Except that we should probably change the definition to exclude 127, seems to me. > > On Apr 25, 6:43 pm, pbreit wrote: >> CLEANUP() seems to be removing more characters than the Book would sugges

[web2py] Re: CLEANUP() removing too many characters

2011-04-25 Thread Massimo Di Pierro
True. It should do what the book says. On Apr 25, 6:43 pm, pbreit wrote: > CLEANUP() seems to be removing more characters than the Book would suggest. > > "It just removes all characters whose decimal ASCII codes are not in the > list [10, 13, 32-127]" > > However the regex is '[^ \n\w]' which I