[web2py] scripts/cpdb.py is Python 2.7 only

2014-08-14 Thread Stefan Scholl
scripts/cpdb.py uses modules that are only available with Python 2.7 and syntax that isn't available in Python 2.5 Are the scripts an exception to the pledge for backward compatibility? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py

[web2py] Re: Ractive.js

2014-07-06 Thread Stefan Scholl
eric cuver wrote: > My eyes struck Ractive.js and I want to test it with Web2py. Web2py however > uses also {{ }} as the templating characters. Ractive uses these characters > also. how i Can be done ? These are handlebars templates, am I right? Put them in separate files and make a raw includ

[web2py] Raw include to solve Handlebars problem

2014-06-24 Thread Stefan Scholl
I wanted to use Ember.js and the Handlebars are clashing with web2py's delimiters. There are many solutions to this problems. This is another one: class RAW_INCLUDE(XML): """ {{=RAW_INCLUDE('views/default/hbs/blah.hbs')}} """ def __init__(self, filename): self.filename = filenam

[web2py] Re: BrowserID web2py authentication plugin done! Please test

2012-11-02 Thread Stefan Scholl
Seems like this plugin isn't supported/updated. It still connects to browserid.org (They changed the name from Browser ID to Persona.) (in contrib directory to web2py, and the google code project.) And is there a reason to redirect to http://google.com on failed logins? Nearly everything else is a

[web2py] Re: An insult to web2py ?

2012-05-03 Thread Stefan Scholl
António Ramos wrote: > a person just wrote this about web2py in a portuguese forum > Anyone care to coment? I recognize the language from about 1/4 of the spam I receive.

[web2py] Re: Images work in IE9, vanish in firefox

2012-04-29 Thread Stefan Scholl
Simon Pickles wrote: > Thanks for the reply. Oddly there is no missing image icon. The > alt text seems to flash up then disappear. Don't try to load the whole page, just the image with its image URL. This way you could see if there is any error reported.

[web2py] Re: Default table schema for the Auth tables

2012-04-13 Thread Stefan Scholl
cyan wrote: > definitions for each of them, if possible. In addition, can we remove > fields from these tables? I know we can add extra fields or re-define the I removed the name fields from auth_user and then some navbar function wrote "Hello None,". OK, some minor problem. But you can't know

[web2py] Re: No DB queries in web2py shell?

2012-03-17 Thread Stefan Scholl
Anthony wrote: > I highly recommend just doing this: > > python web2py.py -S myapp -M -N > > in a regular shell, and skip the web-based shell. You can even do There is no python executable in the Windows version of web2py.

[web2py] Re: No DB queries in web2py shell?

2012-03-17 Thread Stefan Scholl
Stefan Scholl wrote: > Overall conclusion: Queries in the web2py web shell work on Mac, > with some minor glitch. But different symptoms than the ones on > Windows. Have to check again on Windows. I can't test it this weekend. Windows is for work days. But ... ... ACTUALLY:

[web2py] Re: No DB queries in web2py shell?

2012-03-17 Thread Stefan Scholl
Stefan Scholl wrote: > Maybe this was a bad app to test the shell problem. There's a > > I'll make a cleaner testcase later. On MacOS X 10.7, with Mac version of Web2py: OK, new and simple app, SQLite, web2py 1.99.7. In db.py I define a table "foo":

[web2py] Re: No DB queries in web2py shell?

2012-03-17 Thread Stefan Scholl
Stefan Scholl wrote: > Stefan Scholl wrote: >> Person and dog inserted via database admin. After that the shell >> from the admin interface was used. The variable dogs was >> undefined after that. And no output with just >> "db().select(db.dog.ALL)". > &

[web2py] Re: No DB queries in web2py shell?

2012-03-16 Thread Stefan Scholl
Stefan Scholl wrote: > Person and dog inserted via database admin. After that the shell > from the admin interface was used. The variable dogs was > undefined after that. And no output with just > "db().select(db.dog.ALL)". Tested the same on a Mac, web2py 1.99.7, the Mac

[web2py] Re: No DB queries in web2py shell?

2012-03-16 Thread Stefan Scholl
hile, but I seem to > recall having problems with this a long time ago? I always use a standard > OS shell instead. > > Anthony > > On Thursday, March 15, 2012 3:14:56 PM UTC-4, Stefan Scholl wrote: >> >> Sorry, my "bug report" was a bit short. Was called to

[web2py] Re: No DB queries in web2py shell?

2012-03-15 Thread Stefan Scholl
Web interface. On Windows, 127.0.0.1:8000 Michele Comitini wrote: > did you do? > > python web2py.py -M -S > > mic > > Il 15 marzo 2012 09:12, Stefan Scholl ha scritto: >> web2py 1.99.7 for Windows. >> >> Example app, inserted 1 person and 1 dog. >

[web2py] Re: No DB queries in web2py shell?

2012-03-15 Thread Stefan Scholl
oes not > work for database transactions, so you may need to use a regular OS shell. > > Anthony > > On Thursday, March 15, 2012 4:12:10 AM UTC-4, Stefan Scholl wrote: >> >> web2py 1.99.7 for Windows. >> >> Example app, inserted 1 person and 1 dog. >&g

[web2py] No DB queries in web2py shell?

2012-03-15 Thread Stefan Scholl
web2py 1.99.7 for Windows. Example app, inserted 1 person and 1 dog. In the shell: dogs = db().select(db.dog.ALL) Nothing there. And "dogs" isn't defined.

[web2py] References in the book are broken

2012-01-27 Thread Stefan Scholl
I'd like to visit the referenced pages from http://www.web2py.com/book/default/chapter/01#Security but I only get the error "invalid function (default/reference)" Broken: http://www.web2py.com/books/default/reference/29/pythonsecurity http://www.web2py.com/books/default/reference/29/owasp Accordi

[web2py] Re: new book now available in HTML (english, japanese, italian)

2012-01-19 Thread Stefan Scholl
Stefan Scholl wrote: > Johann Spies wrote: >> [-- text/plain, encoding 7bit, charset: ISO-8859-1, 8 lines --] >> >> It is working for me. Perhaps you should try again. > > Nope, still gone. When I look at the response header I see it's a > 404 NOT FOUND. &

[web2py] Re: new book now available in HTML (english, japanese, italian)

2011-12-21 Thread Stefan Scholl
Johann Spies wrote: > [-- text/plain, encoding 7bit, charset: ISO-8859-1, 8 lines --] > > It is working for me. Perhaps you should try again. Nope, still gone. When I look at the response header I see it's a 404 NOT FOUND. http://web2py.com/book/ instead of http://web2py.com/book See the addi

[web2py] Re: new book now available in HTML (english, japanese, italian)

2011-12-21 Thread Stefan Scholl
Massimo Di Pierro wrote: > The latest book edition (4th) is now available for free here: > >http://web2py.com/book I have http://web2py.com/book/ in my bookmarks and get an "invalid request" now.

[web2py] Re: web2py 1.99.3 is OUT

2011-12-11 Thread Stefan Scholl
This was just a on the fly test in Firebug. And it doesn't feel right to insert some random BR in there. Oh, how I hate floats. You can't do without them and then something random happens ... Massimo Di Pierro wrote: > Can you emailed me the fixed layout.html? > > On Dec

[web2py] Re: web2py 1.99.3 is OUT

2011-12-10 Thread Stefan Scholl
Massimo Di Pierro wrote: > The new web site layout needs work but we put it out there hoping for > more feedback. The announcement "2011 BOSSIE AWARD FOR OPEN SOURCE DEVELOPMENT SOFTWARE" is cut off and too far on the right in Firefox 9.0 Beta on Mac OS X 10.6. Haven't found a good solution, but

[web2py] Re: Download of big files broken

2011-06-20 Thread Stefan Scholl
Forget it. (If this would be a real newsgroup I would cancel the article.) Forgot about the problems on localhost. Stefan Scholl wrote: > I had to do something perverted to save the project: I make a > local redirect to a PHP script, which uses readfile > <http://de.php.n

[web2py] Re: Download of big files broken

2011-06-20 Thread Stefan Scholl
ndows > and cannot reproduce the problem. > > I do not doubt you experience this issue. In order to try isolate > better what may be causing it... is there anybody else having this > problem with large files download? > > Massimo > > On Jun 20, 2:53 am, Stefan Schol

[web2py] Re: Download of big files broken

2011-06-20 Thread Stefan Scholl
t; environ['SERVER_PROTOCOL'] = "1.0" > > Looks like acts as if the protocol of response is the same as the > request but always declare the protocol of the response to be 1.1 even > if the request is 1.0. This may result in keep-alive connections > ignored by the

[web2py] Re: Download of big files broken

2011-06-17 Thread Stefan Scholl
ld happen. HTTP isn't ZModem. ;-) Stefan Scholl wrote: > I have a parameters_XXX.py file from the normal web2py (with > rocket) and used the same IP and port with anyserver.py+Tornado > (and the other one stopped, of course). > > Tested with web2py 1.91.6. Were there any changes r

[web2py] Re: Download of big files broken

2011-06-17 Thread Stefan Scholl
interface is disabled if you are not > form localhost and you are not using https. > Hope this helps. Hope to have you back on the mailing list. > > > On Jun 17, 8:43 am, Stefan Scholl wrote: >> Now I can't access the admin interface, because the password >> isn&#x

[web2py] Re: Download of big files broken

2011-06-17 Thread Stefan Scholl
Now I can't access the admin interface, because the password isn't set. (It isn't reading the stored password.) Stefan Scholl wrote: > OK, it was Rocket. > > Tested it with the old web2py and Tornado 1.2.1 via anyserver.py > and the download is OK. > > >

[web2py] Re: Download of big files broken

2011-06-17 Thread Stefan Scholl
OK, it was Rocket. Tested it with the old web2py and Tornado 1.2.1 via anyserver.py and the download is OK. Stefan Scholl wrote: > The higher value for chunk_size didn't work with a 33 MiB file. Even > in Firefox 4. > So I tried 1.96.4 (Rocket 1.2.2) on Windows XP. > > M

[web2py] Re: web2py with Rocket and Tornado - very simple benchmark

2011-06-17 Thread Stefan Scholl
Stefan Scholl wrote: > You could try to download a big file (>30 MiB) via web2py. Is > Tornado sending everything or currupting the data? > > web2py+Rocket is broken for large downloads. Or I just test it myself. :-) Works. Tornado lets me download a 33 MiB file without p

[web2py] Re: web2py with Rocket and Tornado - very simple benchmark

2011-06-17 Thread Stefan Scholl
You could try to download a big file (>30 MiB) via web2py. Is Tornado sending everything or currupting the data? web2py+Rocket is broken for large downloads.

[web2py] Re: Chunked downloads and corrupt files with Internet Explorer 8 (IE8)

2011-06-16 Thread Stefan Scholl
ts have even worse results. On May 6, 5:51 pm, Massimo Di Pierro wrote: > Can you try 1.95.1 > > On May 6, 6:03 am, Stefan Scholl wrote: > > > > > > > > > The classic download function: > > > def download(): > >     return response.download(req

[web2py] Download of big files broken (was: Chunked downloads and corrupt files with Internet Explorer 8 (IE8))

2011-06-16 Thread Stefan Scholl
switches to "Chrome Frame", to have a realistic test like "normal" users). Download was broken. A few KiB were missing. This was on localhost. Remote tests have even worse results. On 6 Mai, 17:51, Massimo Di Pierro wrote: > Can you try 1.95.1 > > On May 6, 6

[web2py] Re: Chunked downloads and corrupt files with Internet Explorer 8 (IE8)

2011-06-15 Thread Stefan Scholl
Is nobody else experiencing this problem? Is nobody using Internet Explorer to download more than 64KiB from a web2py app? On 6 Mai, 13:03, Stefan Scholl wrote: > The classicdownloadfunction: > > defdownload(): >     return response.download(request, db) > > I'm

[web2py] Re: Chunked downloads and corrupt files with Internet Explorer 8 (IE8)

2011-05-08 Thread Stefan Scholl
Sorry, no time for updates at the moment. Updated this project 2 times and every time it broke something. Haven't seen anything related to downloads, streaming etc. in the changelog, though. On May 6, 5:51 pm, Massimo Di Pierro wrote: > Can you try 1.95.1 > > On May 6, 6:03 am,

[web2py] Chunked downloads and corrupt files with Internet Explorer 8 (IE8)

2011-05-06 Thread Stefan Scholl
The classic download function: def download(): return response.download(request, db) I'm developing on localhost (127.0.0.1, no SSL) and one strange thing happened: Downloads in IE8 (Windows XP) were all corrupt/broken if they weren't below 64KiB in size. Very easy to see with large images.

[web2py] Key error with new DAL and _extra

2011-01-10 Thread Stefan Scholl
Hi! Just updated a project from 1.89.5 to 1.91.6. Got a key error. row._extra['MAX(foo.bar)'] had a problem with the key. The query has a "db.foo.bar.max()," in the select(). (Funny: Can't find anything about _extra and max() again in the book now?) Changed the key to 'max(foo.bar)' and now eve

[web2py] Re: How to switch back to English for the Admin interface?

2010-11-13 Thread Stefan Scholl
On Nov 12, 3:03 pm, mdipierro wrote: > The admin (admin) has a selector at the bottom, it uses cookies to > keep the preferred selected language. Since Version 1.89.1, released 2010-11-12 15:14:36 (In case somebody reads this thread in a few years and thinks I'm blind.)

[web2py] Re: How to switch back to English for the Admin interface?

2010-11-12 Thread Stefan Scholl
. But I've done it in Django and MODx, e.g.) On 10 Nov., 22:04, guruyaya wrote: > I'm not sure how to attach files here, but I've created a patch that > creates a dropdown with all possible languages on the admin. Anyone > wants it? > > On Nov 10, 2:53 pm, Stefan Scho

[web2py] Re: How to switch back to English for the Admin interface?

2010-11-10 Thread Stefan Scholl
I know, but I don't want to use one browser for development (English) and one for the rest (German). On 9 Nov., 14:28, mdipierro wrote: > wait. You should not need to delete files. The language is set by your > browser. > > On Nov 9, 3:41 am, Stefan Scholl wrote: > > &g

[web2py] Re: How to switch back to English for the Admin interface?

2010-11-09 Thread Stefan Scholl
Oops, found it 5 minutes later. In case somebody wants to switch back to English, too: Delete (or rename) your language in applications/admin/languages

[web2py] How to switch back to English for the Admin interface?

2010-11-09 Thread Stefan Scholl
Just upgraded web2py and now I get everything in German. That's not a good idea if you are a programmer. The programming world and all the terms are English. And in case of an error I can't ask here, because you can't understand the error messages. :-( Is there a way to switch back the Admin inter

[web2py] How switch back to English for the Admin interface?

2010-11-09 Thread Stefan Scholl
Just upgraded web2py and now I get everything in German. That's not a good idea if you are a programmer. The programming world and all the terms are English. And in case of an error I can't ask here, because you can't understand the error messages. :-( Is there a way to switch back the Admin inter

[web2py] onvalidation with form.request_vars instead of form.vars?

2010-06-24 Thread Stefan Scholl
Hi! I'm validating a self referencing field via onvalidation parameter of crud.update(). My function checks if this field is the same as the id and emits an error in this case (setting form.errors.ref_field). (form is the parameter for the function given to onvalidation) I read the example to onv

[web2py] Re: Fixed book or source to book?

2010-06-22 Thread Stefan Scholl
On Jun 21, 1:50 pm, cjrh wrote: > On Jun 21, 9:59 am, Stefan Scholl wrote: > > > There are (3 month old) comments on those > > pages who address this, but nothing got changed. > > I fixed a couple recently.  If you send me links, I can try to get a > few more? Very

[web2py] Fixed book or source to book?

2010-06-21 Thread Stefan Scholl
The book is very nice. But there are some places with broken code which make the examples pretty useless. Most of the time it's something with % in it. There are (3 month old) comments on those pages who address this, but nothing got changed. Is there any repository with the source to the book? So

[web2py:14025] Re: Setting the value of a form field after accepting the form

2008-12-22 Thread Stefan Scholl
gt; > or > > form[0][0]['value'] = "Foo" > > or > > textarea=TEXTAREA(_name="text", _cols="80", _rows="10", > requires=IS_NOT_EMPTY()) > form = FORM(FIELDSET(textarea), INPUT(_type="submit")) > if form.accepts

[web2py:14021] Setting the value of a form field after accepting the form

2008-12-22 Thread Stefan Scholl
This form: form = FORM(FIELDSET(TEXTAREA(_name="text", _cols="80", _rows="10", requires=IS_NOT_EMPTY())), INPUT(_type="submit")) After!(!) accepting the form I want to change the value of the TEXTAREA. I came up with the following: form.components[0].components[0].components[0] = "Foo" This loo

[web2py:13937] How about selling the PDF to the web2py book directly, without Lulu?

2008-12-20 Thread Stefan Scholl
The Euro is strong and the PDF is a bargain, but Lulu wants me to register with the complete address. I have a paypal account, because I need it from time to time. I don't need Lulu. How about building an e-commerce app to sell the PDF? --~--~-~--~~~---~--~~ You

[web2py:11217] Some code in Appliance "GeoIP" gives a bad example

2008-11-05 Thread Stefan Scholl
Hi! In controller file default.py: data = ZipFile(StringIO(urlopen("http://www.maxmind.com/download/ geoip/database/GeoIPCountryCSV.zip").read())) data = StringIO(data.read(data.namelist()[0])) while True: chunk = data.readline() if not chu