[web2py:30833] Re: web2py source download problems in the secured enterprise environment

2009-09-12 Thread Jonathan Lundell
On Sep 12, 2009, at 9:30 AM, Babu wrote: > I have noticed, that I not able to successfully download web2py source > file in .zip format due to some kind of controls put in our company. > Download completes successfully but the resulting file is not > unzipable. > > Would it be possible to provide

[web2py:30835] Re: web2py source download problems in the secured enterprise environment

2009-09-12 Thread Jonathan Lundell
On Sep 12, 2009, at 9:30 AM, Babu wrote: > I have noticed, that I not able to successfully download web2py source > file in .zip format due to some kind of controls put in our company. > Download completes successfully but the resulting file is not > unzipable. > > Would it be possible to provide

[web2py:30991] Re: cookbook unzip error

2009-09-14 Thread Jonathan Lundell
On Sep 14, 2009, at 9:09 AM, mdipierro wrote: > > Just posted. > > http://groups.google.com/group/web2py/browse_thread/thread/796b11e9e88f552b > > Please try again and let me know. FWIW, I just got a good download with SL. > > On Sep 14, 10:58 am, Wes James wrote: >> Odd - this unzips on leopa

[web2py:31026] Re: some questions for web2py.

2009-09-14 Thread Jonathan Lundell
On Sep 14, 2009, at 4:26 PM, Graham Dumpleton wrote: > > > > On Sep 15, 12:14 am, mdipierro wrote: >> The web2py_manual_cut.pdf is from the second edition. > > When I downloaded it yesterday and when I downloaded it again just > now, it contains mod_wsgi setup example from first edition. So, eit

[web2py:31052] Re: tip of the day: icons in menu

2009-09-15 Thread Jonathan Lundell
On Sep 13, 2009, at 11:00 PM, mdipierro wrote: > In web2py you create a menu like > >response.menu=[['Title',False,URL(...),[]] > > where [] is a submenu. > > You place an icon close to the title by doing > >response.menu=[[TAG[''](IMG(_src=icon,'Title'),False,URL(...),[]] > > where icon

[web2py:31146] Re: ticket tracking

2009-09-16 Thread Jonathan Lundell
On Sep 16, 2009, at 1:18 PM, David Zejda wrote: > > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Hello, > > I returned to examine the problem more deeply, but now it behaves > differently and I do not know why, I do not remember any change, which > could cause the change. > > Now the error

[web2py:31283] Re: Auth customization

2009-09-18 Thread Jonathan Lundell
On Sep 18, 2009, at 1:06 PM, waTR wrote: > Related question though... how can one check if password entered > matches password stored in DB for that user? When I retrieve the > stored password via select(), it is encrypted. How does Auth decrypt? > Where can I find that code (what file)? Briefly

[web2py:31291] Re: Auth customization

2009-09-18 Thread Jonathan Lundell
ld] == form.vars.get (passfield, ''): # success user = temp_user The values being compared are hashes, because the field in question requires IS_CRYPT(), which really doesn't do anything but hash the value. >

[web2py:31376] Re: Auth customization

2009-09-20 Thread Jonathan Lundell
It happens in the IS_CRYPT() validation, which returns the hashed value of the field. > > The above code doesn't show that translation... > > > > > > On Sep 18, 5:08 pm, Jonathan Lundell wrote: >> On Sep 18, 2009, at 4:44 PM, waTR wrote: >> >> >&

[web2py:31377] Re: Auth customization

2009-09-20 Thread Jonathan Lundell
commented. This is a case in point. It's not at all obvious to the casual reader (it wasn't to me when I first read it) how password checking is handled. > On Sep 18, 5:08 pm, Jonathan Lundell wrote: >> On Sep 18, 2009, at 4:44 PM, waTR wrote: >> >> >> &g

[web2py:31412] Re: Auth customization

2009-09-21 Thread Jonathan Lundell
On Sep 21, 2009, at 12:02 AM, Fran wrote: > On Sep 21, 5:13 am, waTR wrote: >> Is it possible to convert the request.vars.get(passfied, '') to the >> same hash form as you would get from using form() ? > > Yes: > myhash = hmac.new(auth.settings.hmac_key, request.vars.get(passfield, > ''), hashli

[web2py:31420] Re: Auth customization

2009-09-21 Thread Jonathan Lundell
de behind them...without re- > doing their work in any-way...this includes re-building their forms in > web2py using FORM. Well, that's reasonable. But I think it's desirable to use common code for hashing passwords when they're first written to the database and when they'

[web2py:31614] Re: Almost working on the dreamhost server... $50 to the person that can make this a script!

2009-09-24 Thread Jonathan Lundell
On Sep 24, 2009, at 7:40 AM, pwoolf wrote: > Thanks for the suggestion Yarko. Here is the script attached. A small correction. I'm doubtful that os.system("cd ~/") will work as you expect, since it's going to change the directory in a child process, and not affect the caller's environment (

[web2py:31616] Re: Almost working on the dreamhost server... $50 to the person that can make this a script!

2009-09-24 Thread Jonathan Lundell
On Sep 24, 2009, at 8:27 AM, Jonathan Lundell wrote: > > On Sep 24, 2009, at 7:40 AM, pwoolf wrote: > >> Thanks for the suggestion Yarko. Here is the script attached. > > A small correction. I'm doubtful that > > os.system("cd ~/") > > will wo

[web2py:31703] Re: help from a mac user

2009-09-26 Thread Jonathan Lundell
On Sep 26, 2009, at 12:33 PM, mr.freeze wrote: > > Can someone with a mac please view this site and tell me what font it > defaults to?: > > http://www.web2pyslices.com/main/default/index It's going to be a function of available fonts, not the browser or system. Macs have Arial and Helvetica,

[web2py:31708] Re: help from a mac user

2009-09-26 Thread Jonathan Lundell
l, Helvetica; use font-family: "Segoe UI", Arial, Helvetica, sans-serif; Also, you might want to check your CSS syntax: http://jigsaw.w3.org/css-validator/validator?uri=http://www.web2pyslices.com/main/default/index In particular, // is not a CSS comment delimiter. > > On

[web2py:31710] Re: help from a mac user

2009-09-26 Thread Jonathan Lundell
fixing. > > On Sep 26, 3:06 pm, Jonathan Lundell wrote: >> On Sep 26, 2009, at 1:00 PM, mr.freeze wrote: >> >> >> >>> Thanks, a friend was telling me that it was defaulting to Serif. I >>> think he is confused. >> >> On general principle

[web2py:31712] Re: help from a mac user

2009-09-26 Thread Jonathan Lundell
On Sep 26, 2009, at 1:42 PM, mr.freeze wrote: > > I fixed them. That site is really handy. Thanks again! It is. It's linked, along with some other useful stuff, from http://www.w3.org/ . > > On Sep 26, 3:30 pm, Jonathan Lundell wrote: >> On Sep 26, 2009, at 1

[web2py:31713] Re: help from a mac user

2009-09-26 Thread Jonathan Lundell
On Sep 26, 2009, at 1:49 PM, Jonathan Lundell wrote: > > On Sep 26, 2009, at 1:42 PM, mr.freeze wrote: > >> >> I fixed them. That site is really handy. Thanks again! > > It is. It's linked, along with some other useful stuff, from > http://www.w3.org/ I

[web2py:31763] Re: Potential bugs in auth system.

2009-09-27 Thread Jonathan Lundell
On Sep 27, 2009, at 1:31 PM, mr.freeze wrote: > > Not sure if it matters but RFC 2142 is from 1997 .RFC 2821 is from > 2001. But as a matter of practicality, I would just do like google > and make them case insensitive. 2821 is just a requirement that SMTP MTAs preserve mailbox case; web2py s

[web2py:31768] Re: IS_EMAIL() validation bug?

2009-09-27 Thread Jonathan Lundell
There's a bug. Massimo, here's a patch with updated test cases. http://lobitos.net/web2py-patches/gluon/validators.py On Sep 27, 2009, at 3:50 PM, Russell wrote: > > Hi, > > It seems that email addresses without a user portion (eg, > '@whatever.com') will pass IS_EMAIL() validation. Is this

[web2py:31817] Re: vulnerability discovered and fixed in markdown

2009-09-28 Thread Jonathan Lundell
On Sep 28, 2009, at 2:53 PM, mr.freeze wrote: > > Can we just replace gluon.contrib.markdown2.py or were there other > changes? Trying to avoid an upgrade on my live sites. That seems to be the only change (well, and the version number). > > On Sep 28, 4:42 pm, Massimo Di Pierro wrote: >> As y

[web2py:31847] Re: Web2py + Wing IDE + Mac Machine....

2009-09-28 Thread Jonathan Lundell
On Sep 28, 2009, at 6:39 PM, Yannick wrote: > > Hello mate, > > Does anyone use Wing IDE on a Mac machine with Web2py installed > If yes can you please let me know how you configured Web2py and > Wing ??? Because I followed this instruction > http://www.wingware.com/doc/howtos/web2py > and

[web2py:31851] Re: Web2py + Wing IDE + Mac Machine....

2009-09-28 Thread Jonathan Lundell
On Sep 28, 2009, at 6:39 PM, Yannick wrote: > Does anyone use Wing IDE on a Mac machine with Web2py installed > If yes can you please let me know how you configured Web2py and > Wing ??? Because I followed this instruction > http://www.wingware.com/doc/howtos/web2py > and I got this error

[web2py:31868] Re: Web2py + Wing IDE + Mac Machine....

2009-09-29 Thread Jonathan Lundell
nd not gluon, since they're in the same directory. Try setting a breakpoint at import gluon.import_all and look at sys.path at that point. > > On Sep 29, 1:21 am, Jonathan Lundell wrote: >> On Sep 28, 2009, at 6:39 PM, Yannick wrote: >> >>> Does anyone use W

[web2py:31869] Re: selecting part of model to run

2009-09-29 Thread Jonathan Lundell
On Sep 29, 2009, at 7:03 AM, mdipierro wrote: > If you still need more speed move the table definitions in a module > (not a model) and import it from the model. I would not recommend this > to everybody but 93 is a lot. How does that speed things up? (Just curious.) --~--~-~--~~---

[web2py:31870] Re: Web2py + Wing IDE + Mac Machine....

2009-09-29 Thread Jonathan Lundell
version, if you're going to be debugging. Much easier. > > Thanks > > > On Sep 29, 10:04 am, mdipierro wrote: >> You can try add gluon to the pythonpath or move it in a folder >> already >> in the python path. >> >> On Sep 29, 1:21 am, Jonatha

[web2py:32155] Re: Input validation

2009-10-03 Thread Jonathan Lundell
On Oct 3, 2009, at 7:50 AM, mdipierro wrote: > something like this? > > def MYVALIDATOR: >def __init__(self,error_message): > self.error_message=error_message >def __call__(self,value): > if not re.compile('^([a-zA-Z]*[ ]*[á]*[é]*[í]*[ó]*[ú]*)+ Why not: > if n

[web2py:32259] Re: web2py + pyjamas desktop = a desktop framework?

2009-10-05 Thread Jonathan Lundell
On Oct 5, 2009, at 5:02 PM, Álvaro Justen [Turicas] wrote: > It depends on how you will distribute your application. > My mother uses a system based on web2py and I've created a shell > script to: > - kill any web2py.py process > - start a new web2py.py process > - open firefox in http://localh

[web2py:32323] Re: URLs in static files

2009-10-06 Thread Jonathan Lundell
On Oct 6, 2009, at 1:35 PM, mdipierro wrote: > It is good practice to put in the CSS only relative urls to other > static files. That is not a problem with web2py. > > If you need to include in the CSS urls generated by {{=URL()}} > then you should promote the css from a static file to a dyna

[web2py:32329] Re: URLs in static files

2009-10-06 Thread Jonathan Lundell
ontent is a relatively small part of it. > -Eric > > On Oct 6, 2:29 pm, Jonathan Lundell wrote: >> On Oct 6, 2009, at 1:35 PM, mdipierro wrote: >> >>> It is good practice to put in the CSS only relative urls to other >>> static files. That is n

[web2py:32397] Re: URLs in static files

2009-10-07 Thread Jonathan Lundell
es in /views/css/ ? > All it would need to do is run the __cssheaders() function and return > dict(), but it feels unnecessary to maintain a list of functions when > there are files. > > -Eric > > On Oct 6, 2:29 pm, Jonathan Lundell wrote: >> On Oct 6, 2009, at 1:35 PM

[web2py:32404] Re: URLs in static files

2009-10-07 Thread Jonathan Lundell
the logic (where?) that creates the default html headers could recognize that it's got a .css file and create css headers instead. > > On Oct 7, 8:19 am, Jonathan Lundell wrote: >> On Oct 6, 2009, at 2:54 PM, Eric Vicenti wrote: >> >> >> >>> Thank

[web2py:32441] Re: URLs in static files

2009-10-07 Thread Jonathan Lundell
#x27;s desire for a single controller solution for CSS files, which is a different issue, but it does eliminate the need for the __cssheaders() function. http://lobitos.net/web2py-patches/gluon/contenttype.py http://lobitos.net/web2py-patches/gluon/main.py > > Massimo > > On Oct 7, 10

[web2py:32559] Re: web2py wiki

2009-10-09 Thread Jonathan Lundell
On Oct 9, 2009, at 1:22 AM, Joe Barnhart wrote: > We could make the wiki even simpler... > > Get rid of "comments" on each page. The wiki IS "comments" it > doesn't need additional comments! > > Get rid of tags. Tags imply we know in advance what the structure > of the wiki is. We don't. I

[web2py:32645] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]

2009-10-10 Thread Jonathan Lundell
On Oct 10, 2009, at 1:22 PM, mdipierro wrote: > When you post about an issue and the issue is solved and you email a > response saying the issue is solved make sure you edit the subject and > append [SOLVED]. > > That is all. > > Most people, including me, do not use email for posting/reading. We

[web2py:32690] Re: How to Change the css style color and text of submit button on a crud.create form in controller

2009-10-11 Thread Jonathan Lundell
On Oct 11, 2009, at 2:04 PM, mr.freeze wrote: > > The example I gave was for auth membership. Say you wanted to style > the form based on which group they were a member of. You would need a > style sheet for each group. Also, what would happen when a new group > was created? You could generat

[web2py:32705] Re: hg and google

2009-10-11 Thread Jonathan Lundell
On Oct 11, 2009, at 5:37 PM, mdipierro wrote: > It is one of those things that is not technically difficult but would > require lots of people to change habits. Starting with me. I am still > leaning toward switching but I would like to hear if there is any > opposition to this. It does look lik

[web2py:32743] Re: security bug in Django, what about web2py?

2009-10-12 Thread Jonathan Lundell
On Oct 12, 2009, at 8:32 AM, carlo wrote: > This is the reported bug: > > http://code.djangoproject.com/changeset/11603 > > do you think web2py is also affected? I think that regex_url is OK, and I'm semi-sure that the email validator is OK. I'm not so sure about the http url validator. --~--

[web2py:32833] Re: IS_MATCH

2009-10-13 Thread Jonathan Lundell
On Oct 13, 2009, at 7:59 PM, DenesL wrote: > > Hi Sophie, > > you want IS_MATCH('^[a-zA-Z áÁéÉíÍóÓúÚ]+$',...) and you can drop > IS_NOT_EMPTY(...). > The regex above means: match a string composed only of the characters > listed from beginning to end with minimum length=1. > Yours said: match a s

[web2py:32837] Re: IS_MATCH

2009-10-13 Thread Jonathan Lundell
Why check for a-z (for example)? > > Massimo > > On Oct 13, 10:08 pm, Jonathan Lundell wrote: >> On Oct 13, 2009, at 7:59 PM, DenesL wrote: >> >> >> >>> Hi Sophie, >> >>> you want IS_MATCH('^[a-zA-Z áÁéÉíÍóÓúÚ]+$',...)

[web2py:32873] Re: Eclipse, json and reaching breaking point

2009-10-14 Thread Jonathan Lundell
On Oct 14, 2009, at 1:05 AM, Carl wrote: > > replying to this post myself to kick Google Groups to list it! FWIW, your first message showed up yesterday afternoon as web2py: 32811. No replies, though. > > On Oct 13, 10:47 pm, Carl wrote: >> hi, >> >> I'm using XP, Eclipse, Web2py/json/pyjs an

[web2py:32888] GG search FAIL

2009-10-14 Thread Jonathan Lundell
On Oct 14, 2009, at 1:02 AM, Carl wrote: > I've replied to this message as the original (while in my browser > history) is not listed by Google Groups. I did a little checking on this, with the following results. 1. I received Carl's original message (yesterday) via email. 2. I found the messa

[web2py:33017] Re: Case sensitive application name

2009-10-16 Thread Jonathan Lundell
On Oct 16, 2009, at 7:32 AM, mr.freeze wrote: > No, I think you are right (after doing some reading). Can I use > routes.py to make my application name (or entire url) case > insensitive? You could in principle (by patching rewrite.py) force all incoming paths to lower case, which would accom

[web2py:33018] Re: Case sensitive application name

2009-10-16 Thread Jonathan Lundell
On Oct 16, 2009, at 8:41 AM, Thadeus Burgess wrote: > I dislike capital letters in the URL, just because of case in- > sensitive websites. You type it in to the address bar, and you get a > 404. > > http://tools.ietf.org/html/rfc3986 > > All though the document it talks about how URL/URI should

[web2py:33035] Re: It is alive!!! (the new book is on sale)

2009-10-16 Thread Jonathan Lundell
On Oct 16, 2009, at 1:29 PM, mdipierro wrote: > You may also want to consider having a bookstore buy a copy for you > (from the ISBN) instead of ordering via Wiley so that it will be in > their records. Remind us what the ISBN is, please. http://www.web2py.com/examples/default/docs still links

[web2py:33042] Re: It is alive!!! (the new book is on sale)

2009-10-16 Thread Jonathan Lundell
On Oct 16, 2009, at 3:16 PM, mr.freeze wrote: > >>> http://www.web2py.com/examples/default/docs still links to the >>> first edition. > Strange, it brings up the 2nd edition for me. I'm referring to the Amazon and Wiley hard-copy links. > > On Oct 16, 3:42

[web2py:33084] Re: import static CSS files

2009-10-17 Thread Jonathan Lundell
On Oct 17, 2009, at 11:46 AM, Celso wrote: > > Hi, > I have a html file in the myapp/static directory that I am opening > using web2py. > > I can sucessfully import the javascript content from a subdirectory of > myapp/static using relative path, for example, src="./dojoroot/dojo/ > dojo.js". > B

[web2py:33205] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
On Oct 20, 2009, at 6:33 AM, mdipierro wrote: > > In trunk now. Please try it. I notice that the int & float versions use conflicting interpretations of "between": if value == fvalue and self.minimum <= value < self.maximum: if self.minimum <= value <= self.maximum

[web2py:33219] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
On Oct 20, 2009, at 7:49 AM, mdipierro wrote: > > I agree, fixing in trunk. A (minor) quibble: "integer number" sounds redundant to me. I'd use "whole number", "integer value", or simply "integer" instead. > > Massimo > > On Oct

[web2py:33223] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
On Oct 20, 2009, at 10:16 AM, mdipierro wrote: > I think "integer number" is the proper way but I am not a native > english speaker. Any english speaker can help us on this? Here's the (Oxford American) dictionary entry: integer |ˈɪntədʒər| noun 1 a whole number; a number that is not a fraction

[web2py:33225] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
for my Aunt Polly. > > On Oct 20, 12:19 pm, Jonathan Lundell wrote: >> On Oct 20, 2009, at 10:16 AM, mdipierro wrote: >> >>> I think "integer number" is the proper way but I am not a native >>> english speaker. Any english speaker can help us on this?

[web2py:33229] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
we could do it. Example: 'enter a valid email address'. > > On Tue, Oct 20, 2009 at 12:59 PM, mdipierro > wrote: > > You may be right but to me "whole number" does not sound good. Anyway, > one can use internationalization to fix this. > > I w

[web2py:33247] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
eneral, 'enter ' is more helpful and friendly than >> 'invalid '. It's not possible in every case, but in many >> cases we could do it. Example: 'enter a valid email address'. >> >> >> >>> On Tue, Oct 20, 2009 at 12:59 PM, mdipie

[web2py:33260] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
On Oct 20, 2009, at 5:24 PM, mdipierro wrote: > > please email it to me when done. Thanks. Are you OK with the patches? I don't want to do the doctests until they're settled, since the error messages figure in the tests. > > On Oct 20, 6:42 pm, Jonathan Lundell wrote:

[web2py:33266] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
y (not surprising, really) is this one: >>> IS_FLOAT_IN_RANGE(1,5)(5.1) (5.0996, 'enter a number between 1.0 and 5.0') Do we care? > > massimo > > On Oct 20, 9:25 pm, Jonathan Lundell wrote: >> On Oct 20, 2009, at 5:24 PM, md

[web2py:33279] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-20 Thread Jonathan Lundell
ternal > representation is what it is. It's routine floating point precision issues, I think. The current patch has doctests for everything that changed significantly. But I think I'll add tests for at least some of the other validations. I don't have to to make them thorough,

[web2py:33340] Re: more specific IS_INT_IN_RANGE / IS_FLOAT_IN_RANGE error message

2009-10-21 Thread Jonathan Lundell
On Oct 21, 2009, at 10:03 AM, Iceberg wrote: > It is a little bit surprising and happy to see these error_message > draw enough attention. :-) So is it time to also consider my proposal > more than one month before? > http://groups.google.com/group/web2py/browse_frm/thread/8cbe658406be595f > >

[web2py:33607] Re: Web2py concerns

2009-10-24 Thread Jonathan Lundell
On Oct 24, 2009, at 11:08 AM, Thadeus Burgess wrote: > My only complaint about the web editor is it is buggy. Every once in > a while (like every 5 minutes) it will bug up, and not display the > code correctly, hard to explain so heres a screenshot > > http://static.thadeusb.com/web2py_web_edi

[web2py:33608] Re: Code Snippets w examples

2009-10-24 Thread Jonathan Lundell
On Oct 24, 2009, at 11:05 AM, znafets wrote: > I think Sebastian is right. Being in a similar place I did not manage > yet to find out how to create a form with self located fields and > styles and attributes. Better said all of the examples I found handle > with the default layout of the SQLFORM

[web2py:33861] Re: Google Groups is Dead

2009-10-27 Thread Jonathan Lundell
On Oct 27, 2009, at 4:56 PM, mdipierro wrote: > > We are 10x smaller so I guess we get 10x less spam. We get about > 50-100 spam emails/day. We block the emails used by spammers. We had > only one reported case of actual user being spoofed. That did cause > some trouble for the user. > > I am not

[web2py:33945] Re: bug in Rows.last()

2009-10-28 Thread Jonathan Lundell
On Oct 28, 2009, at 9:58 AM, mdipierro wrote: > > On a third thougth. Mr Freeze original names are better (find and > filter it is). Your use of 'filter' (or my confusion about it) for both cases illustrates its ambiguity. How about 'find' and 'exclude'? > I added slices too. Here is an examp

[web2py:33947] Re: bug in Rows.last()

2009-10-28 Thread Jonathan Lundell
On Oct 28, 2009, at 10:28 AM, mr.freeze wrote: > > I think you may be right. What about 'remove' instead of filter? Sure. > > On Oct 28, 12:23 pm, Jonathan Lundell wrote: >> On Oct 28, 2009, at 9:58 AM, mdipierro wrote: >> >> >> >>>

[web2py:34065] Re: Dynamically built Form

2009-10-29 Thread Jonathan Lundell
On Oct 29, 2009, at 8:36 AM, Chris S wrote: > > lol, well I've been all around that. Thank you so much, works just > fine now. > > Is there a quick 2-min "why that works" or somewhere you could point > me to as to what that * means/does? Apparently I'm missing out on > something important. It'

[web2py:34073] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
On Oct 29, 2009, at 9:01 AM, mdipierro wrote: > > I do not disagree. Shall we make is_not_empty strip? If it's going to change, how about (also) an optional argument, defaulting to None, that's a string that counts as empty? I'm thinking of the case in which you put instructions to the user

[web2py:34077] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
t. But the point of the change you're suggesting is the same as the one I'm suggesting: IS_EMPTY should match non-empty strings that "count as empty". It's syntactic sugar merely, but sweet nonetheless. > > On Oct 29, 11:18 am, Jonathan Lundell wrot

[web2py:34082] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
On Oct 29, 2009, at 9:57 AM, mdipierro wrote: > > send me a patch OK. Do you want to strip spaces? White space generally? If so, should IS_NULL_OR do the same? > > On Oct 29, 11:31 am, Jonathan Lundell wrote: >> On Oct 29, 2009, at 9:23 AM, mdipierro wrote: >> >

[web2py:34084] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
On Oct 29, 2009, at 10:14 AM, Jonathan Lundell wrote: > > On Oct 29, 2009, at 9:57 AM, mdipierro wrote: > >> >> send me a patch > > OK. > > Do you want to strip spaces? White space generally? If so, should > IS_NULL_OR do the same? I see that stripping is t

[web2py:34100] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
x27;s not true, it's confusing. I'll generate a patch that'll let you decide what to keep. > > On Oct 29, 12:25 pm, Jonathan Lundell wrote: >> On Oct 29, 2009, at 10:14 AM, Jonathan Lundell wrote: >> >> >> >>> On Oct 29, 2009, at 9:57 AM, mdipi

[web2py:34106] Re: IS_NOT_EMPTY validator.

2009-10-29 Thread Jonathan Lundell
he patch. The changes are: * create IS_EMPTY_OR, same as IS_NULL_OR * create a common empty-field test for IS_EMPTY_OR and IS_NOT_EMPTY to share * allow specification of an arbitrary string to be treated as 'empty' * doctests all around > > On Oct 29, 2:46 pm, Jonathan Lundel

[web2py:34254] web2py update script

2009-10-30 Thread Jonathan Lundell
In case anyone is interested. I use it under OS X, but it ought to work under any unixalike. Put it in (say) update.sh in the same directory as web2py/, and run it to: 1. create a snapshot of your current web2py/, renamed to its web2py version 2. download the new source version 3. unzip it

[web2py:34262] Re: web2py update script

2009-10-30 Thread Jonathan Lundell
On Oct 30, 2009, at 8:44 PM, Thadeus Burgess wrote: > I usually just > > svn update && rm -R applications/examples applications/welcome That's cool if you want to update to root; I'm aiming for the release points (with checkpointing). --~--~-~--~~~---~--~~ You

[web2py:34291] Re: web2py update script

2009-10-31 Thread Jonathan Lundell
On Oct 30, 2009, at 8:33 PM, mr.freeze wrote: > This is useful. Perhaps worth making a slice? > http://www.web2pyslices.com/main/default/user/login?_next=/main/slices/make_slice I can do that. Here's an improved version. It zips the old version instead of copying it, and has cleaner messaging

[web2py:34679] Re: Does your Response Flash get in the way?

2009-11-05 Thread Jonathan Lundell
On Nov 5, 2009, at 8:52 AM, Thadeus Burgess wrote: > Instead of putting a timer on response.flash, I moved its location > to another location on the site that does conflict with any text. I like Gmail's approach to flash messages. They're not obtrusive, but they're still prominent enough to b

[web2py:34686] Re: Does your Response Flash get in the way?

2009-11-05 Thread Jonathan Lundell
On Nov 5, 2009, at 12:41 PM, Russell wrote: > It does seem that a nice solution would be to position or shrink the > flash message on the default layout so that it is unlikely to cover > text. But it maybe we are trying to do too much with the flash > message? There are some messages that only

[web2py:34701] Re: Does your Response Flash get in the way?

2009-11-05 Thread Jonathan Lundell
pper function once the html gets more complex than a simple div (or the like). BTW, with this method, does the end up getting escaped? > > On Nov 5, 3:13 pm, Jonathan Lundell wrote: >> On Nov 5, 2009, at 12:41 PM, Russell wrote: >> >>> It does seem that a nice solution

[web2py:34704] Re: Does your Response Flash get in the way?

2009-11-05 Thread Jonathan Lundell
te table. Then you can use a CSS selector like: div.flash table.error { ... } Thanks. > > On Nov 5, 9:28 pm, Jonathan Lundell wrote: >> On Nov 5, 2009, at 1:39 PM, mdipierro wrote: >> >> >> >>> well, you can do >> >>> response.flash=DIV("

[web2py:34883] Re: Charsets and Includes. Or why do my accented words get screwed in includes.

2009-11-08 Thread Jonathan Lundell
On Nov 8, 2009, at 7:33 AM, Benigno wrote: > > I didnt explain myself correctly. I am setting the equiv="Content-Type" content="text/html; charset=iso-8859-1" /> > dinamically when in spanish. However, the accented words still show > badly. The character set specified by the http header takes p

[web2py:35055] Re: Using web2py with jython

2009-11-10 Thread Jonathan Lundell
On Nov 10, 2009, at 12:55 PM, Timbo wrote: > > Massimo, > > I'm trying to rewrite template.py for Jython and I can't seem to > figure out what the re_strings regex is doing. I wrote a routine for > what I thought it was doing and that puts "\n" all over my pages. So > I took it out entirely a

[web2py:35090] Re: floating imprecision

2009-11-11 Thread Jonathan Lundell
On Nov 10, 2009, at 11:49 PM, Richard wrote: > I have some floating point numbers in my database which I need to test > for equality. Numbers like "0.3" are failing an equality test. > So, is there a way to store floating point numbers precisely? Or > should I be using something like: > offset =

[web2py:35091] Re: borken IPV4 validator?

2009-11-11 Thread Jonathan Lundell
On Nov 11, 2009, at 2:32 AM, Frederik Wagner wrote: > I already filed it as a bug some days ago, but should have ask here > before. Could it be, that the IS_IPV4 provider validates erroneous > IPv4's? > > Reproduction in the shell: > 1. type: > a=IS_IPV4() > 2. type e.g.: > a('123.123') > whic

[web2py:35092] Re: New features not documented in book 2 ed.

2009-11-11 Thread Jonathan Lundell
Thank you for this. A suggestion: perhaps the 2ed errata page could have both errata and additions? On Nov 11, 2009, at 3:32 AM, DenesL wrote: > > New features not documented in book 2 ed. > = > > 1.72.1 > * Alias for id field > allows to redefine the

[web2py:35097] Re: New features not documented in book 2 ed.

2009-11-11 Thread Jonathan Lundell
On Nov 11, 2009, at 9:04 AM, DenesL wrote: > You are welcome. > Is all the errata in one place? any volunteers otherwise?. http://wiki.web2py.com/Errata_for_web2py_2nd_Edition_Book > Why have them together (errata & additions)? Perhaps not on the same page, but parallel, and linked. I was th

[web2py:35108] Re: New features not documented in book 2 ed.

2009-11-11 Thread Jonathan Lundell
On Nov 11, 2009, at 10:01 AM, DenesL wrote: > > > On Nov 11, 12:08 pm, Jonathan Lundell wrote: >> On Nov 11, 2009, at 9:04 AM, DenesL wrote: >> >>> You are welcome. >>> Is all the errata in one place? any volunteers otherwise?. >> >> http:/

[web2py:35312] Re: decimal type in web2py

2009-11-13 Thread Jonathan Lundell
On Nov 13, 2009, at 4:09 PM, mdipierro wrote: > > On a second thought. The problem is not the rounding. If we use float > internally we do not have the precision of 1c in $1billion. Float has 53 bits, no? > > On Nov 13, 5:10 pm, villas wrote: >> On Nov 13, 9:59 pm, mdipierro wrote: >> >>>

[web2py:35319] Re: decimal type in web2py

2009-11-13 Thread Jonathan Lundell
On Nov 13, 2009, at 4:36 PM, Massimo Di Pierro wrote: > In theory double has 53 bits. Yet I tried and it does not seem to work > properly. It rounds to the cents. You may want to try the attached > files. Perhaps I am doing something wrong. What are you expecting to see? --~--~-~--

[web2py:35320] Re: decimal type in web2py

2009-11-13 Thread Jonathan Lundell
On Nov 13, 2009, at 5:12 PM, Jonathan Lundell wrote: > > On Nov 13, 2009, at 4:36 PM, Massimo Di Pierro wrote: > >> In theory double has 53 bits. Yet I tried and it does not seem to work >> properly. It rounds to the cents. You may want to try the attached >>

[web2py:35323] Re: decimal type in web2py

2009-11-13 Thread Jonathan Lundell
On Nov 13, 2009, at 4:36 PM, Massimo Di Pierro wrote: > In theory double has 53 bits. Yet I tried and it does not seem to work > properly. It rounds to the cents. You may want to try the attached > files. Perhaps I am doing something wrong. I'm not advocating floating point; I think it's a

[web2py:35340] Re: decimal type in web2py

2009-11-14 Thread Jonathan Lundell
;>>> b=Decimal(repr(a)[0:5]) >>>> print b > 0.099 > > Conversions like the one above are necessary step to get data in/out > of database. > > The more I look into this the more I think we should not support it if > the database does not support it. Perhaps

[web2py:35975] Re: different password reset process

2009-11-24 Thread Jonathan Lundell
On Nov 24, 2009, at 9:14 PM, Wes James wrote: > I've been working on an app that has this type of password reset: > > 1. click on password reset > 2. user types in email address > 3. the user gets an email that has a link that takes them back to the > web2py site > 4. a new password is typed in

[web2py:36130] doctesting routes.py

2009-11-28 Thread Jonathan Lundell
I've implemented a doctest for routes.py. The idea is to modify the doctest as required to verify that your routes.py is doing what you expect. Massimo has the patch, but in the meantime (he's busy) feedback would be useful. Post it here, or send me a note. You'll need to replace gluon/rewrite.

Re: [web2py:36131] doctesting routes.py

2009-11-28 Thread Jonathan Lundell
On Nov 28, 2009, at 4:54 PM, Jonathan Lundell wrote: > I've implemented a doctest for routes.py. The idea is to modify the doctest > as required to verify that your routes.py is doing what you expect. Massimo > has the patch, but in the meantime (he's busy) feedback would be

Re: [web2py:36317] Re: upgrade app

2009-12-01 Thread Jonathan Lundell
On Dec 1, 2009, at 8:04 PM, DenesL wrote: > The question was: > when one does an app upgrade what exactly is upgraded? > > as in: > web2py.py -S myapp -u yes The three standard apps (admin, examples & welcome) are upgraded. Your own apps are never upgraded under any circumstances (well, unless

Re: [web2py:36347] Re: upgrade app

2009-12-02 Thread Jonathan Lundell
On Dec 2, 2009, at 6:28 AM, DenesL wrote: > So there is no such thing as upgrade myapp? > Where did I get this idea... What we really need is a create_myapp--save us all a whole lot of trouble. Part of the Python dwim module... -- You received this message because you are subscribed to the Goo

Re: [web2py:36354] Re: upgrade app

2009-12-02 Thread Jonathan Lundell
On Dec 2, 2009, at 8:02 AM, Thadeus Burgess wrote: > Don't we have create_app from the admin / site screen? Nah; it just clones and renames welcome. I'm asking for the heavy lifting. http://en.wikipedia.org/wiki/DWIM > > -Thadeus > > > > > On Wed

Re: [web2py:36358] Re: upgrade app

2009-12-02 Thread Jonathan Lundell
On Dec 2, 2009, at 8:10 AM, Thadeus Burgess wrote: > I don't understand what you mean. Define heavy lifting. > > our existing create_app does what I mean. Write my app for me. A weak joke, but it's early yet here. > > -Thadeus > > > > > On Wed, D

Re: [web2py:36429] about distribution

2009-12-03 Thread Jonathan Lundell
On Dec 3, 2009, at 9:06 AM, salingrosso wrote: > We can make it a link of the side-bar that is alway there to remind us > that we have an option to upgrade apps if we have not done so. It > would be non-intrusive. The actual popup to point us to the link would > appear only once. > > I think this

Re: [web2py:36434] Re: about distribution

2009-12-03 Thread Jonathan Lundell
On Dec 3, 2009, at 9:18 AM, mdipierro wrote: > It could be even simpler like keep a copy of the VERSION file into > each of the basic apps. What would be in the file? It'd have to be more than the version number and timestamp. > > On Dec 3, 11:12 am, Jonathan Lundell wrote:

Re: [web2py:36438] Re: about distribution

2009-12-03 Thread Jonathan Lundell
rent? Yes, I'm thinking of detecting whether the apps have been modified by the user. A reasonable default policy would be to automatically upgrade (on an app by app basis) apps that have not been modified since installation or the last upgrade. > > On Dec 3, 11:23 am, Jonathan L

Re: [web2py:36440] Re: about distribution

2009-12-03 Thread Jonathan Lundell
gesting. I think you'd want to do it for every file that would be replaced, but are there "unimportant" files? > > -Thadeus > > > > > On Thu, Dec 3, 2009 at 11:34 AM, Jonathan Lundell wrote: > On Dec 3, 2009, at 9:28 AM, mdipierro wrote: > > &g

<    4   5   6   7   8   9   10   11   12   13   >