[web2py] Re: web2py running en AppFog

2014-01-03 Thread webpypy
Hi, Please, translate this EXPLANATION: http://jallander.wordpress.com/2014/01/03/web2py-en-appfog/ >> >> to English. Regards, Ashraf -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py

[web2py] Re: Important New Year News: Edison Award

2014-01-03 Thread Avi A
Good luck :). On Saturday, January 4, 2014 6:08:38 AM UTC+2, Massimo Di Pierro wrote: > > Web2py/me have been nominated for the Edison Award. Please wish web2py > (and me) good luck. :-) > > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/we

[web2py] Re: What is the purpose of data-w2p_disable_with?

2014-01-03 Thread User
Good to know. How can I remove it for all my links? On Monday, December 30, 2013 8:18:11 PM UTC-5, Anthony wrote: > > That's so the link can be temporarily disabled (the text will be replaced > with "Working...") when it is used to trigger an Ajax request. However, I > don't know why it's inclu

[web2py] Re: Important New Year News: Edison Award

2014-01-03 Thread 黄祥
have the wonthefull luck for you and web2py \(^o^)/ best regards, stifan -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message becau

[web2py] Re: How to declare a pre-defined sqlite database

2014-01-03 Thread 黄祥
i think you can do it with the extract_sqlite_models.py that ships with web2py. the path is web2py/scripts/extract_sqlite_models.py. you must have python installed when execute in windows environment. best regards, stifan -- Resources: - http://web2py.com - http://web2py.com/book (Documentation

[web2py] auth signature and enable record versioning

2014-01-03 Thread 黄祥
hi, i wonder what is the correlation between auth signature and enable record versioning. e.g. # on_define_bank def on_define_bank(table): # notnull table.bank.notnull = True # create table : bank db.define_table('bank', Field('bank'), auth.signature, on_define = on_define_bank, format = '%(

[web2py] Important New Year News: Edison Award

2014-01-03 Thread Massimo Di Pierro
Web2py/me have been nominated for the Edison Award. Please wish web2py (and me) good luck. :-) -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You receiv

[web2py] Important New Year News: PyCon 2014 Tutorial

2014-01-03 Thread Massimo Di Pierro
There will be a web2py tutorial at PyCon 2014. https://us.pycon.org/2014/schedule/presentation/133/ Congratulations to Clifford Williams for proposing the tutorial and passing the selection process. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.

[web2py] Re: executesql as_dict=True replacing ids during join

2014-01-03 Thread Massimo Di Pierro
OK. Done. Please check it. On Friday, 3 January 2014 20:54:02 UTC-6, Anthony wrote: > > I agree. Because executesql() can execute any arbitrary SQL, it can't know > how to properly name the columns, so the best approach when there are > duplicate column names is probably just to require explicit

[web2py] Re: parse_as_rest possible problem

2014-01-03 Thread Massimo Di Pierro
I am removing those lines because I cannot find a good reason for them. On Friday, 3 January 2014 09:26:07 UTC-6, Felipe Augusto Meirelles wrote: > > Hi, > > Can some one on the devs team explain this on DAL.py (line 8098): > if count > limits[1]-limits[0]: >

[web2py] Re: executesql as_dict=True replacing ids during join

2014-01-03 Thread Anthony
I agree. Because executesql() can execute any arbitrary SQL, it can't know how to properly name the columns, so the best approach when there are duplicate column names is probably just to require explicit specification via the "colnames" argument. Anthony On Friday, January 3, 2014 9:18:53 PM

[web2py] parse_as_rest possible problem

2014-01-03 Thread Felipe Augusto Meirelles
Hi, Can some one on the devs team explain this on DAL.py (line 8098): if count > limits[1]-limits[0]: return Row({'status':400,'error':'too many records','response':None}) I'm trying to use the parse_as_rest function, sending a request as /auth-us

[web2py] Re: sessions and logout

2014-01-03 Thread Massimo Di Pierro
No because auth.logout(next=...) redirects to he value of next. Next defaults to auth.settings.logout_next which is set to URL('index') What you want is: def logout(): auth.logout(logout_onlogout=lambda user: session.auth=None) On Friday, 3 January 2014 19:44:43 UTC-6, Wonton wrote: > > Hel

[web2py] How to declare a pre-defined sqlite database

2014-01-03 Thread pythonic . jonathan
Hi, I'm new to web2py. I have a SQLite database that must be pre-created and pre-populated (done by a separate python script) and would like to use it in my web2py application. There are currently 22 tables with anything from 2 to 12 columns and I anticipate considerable changes will be made to

[web2py] Re: web2py running en AppFog

2014-01-03 Thread Massimo Di Pierro
I am sorry. I need a little more explanations. :-( On Friday, 3 January 2014 06:46:43 UTC-6, José Antonio López Lorenzo wrote: > > DEMO: http://web2py.eu01.aws.af.cm/ > EXPLANATION: http://jallander.wordpress.com/2014/01/03/web2py-en-appfog/ > SERVER: https://www.appfog.com/ > -- Resources: - ht

[web2py] Re: question about SQLFORM.grid

2014-01-03 Thread Massimo Di Pierro
On Thursday, 2 January 2014 11:41:52 UTC-6, Robert Bjornson wrote: > > Hi all, > > I am a newcomer to web2py, and have what I hope is a simple beginner > question. > > I am following the "mywiki" example in the getting started tutorial. In > it, one can display all the documents for a page > us

[web2py] Re: Can't get web2py working with GAE locally

2014-01-03 Thread Massimo Di Pierro
It is in handlers/gaehandler.py There reason we moved is that we do now want to pollute the main folder and we do now want to overwrote any changes you may have to make to it upon upgrade. You have to cp handlers/gaehandler.py ./ On Thursday, 2 January 2014 20:33:35 UTC-6, Jaime Sempere wrot

[web2py] Re: executesql as_dict=True replacing ids during join

2014-01-03 Thread Massimo Di Pierro
I think if there is a duplicated entry, and as_dict=True we should raise an exception and explain the reasons. Unless there is a way to make this this not ambiguous. On Thursday, 2 January 2014 19:13:26 UTC-6, Anthony wrote: > > This may be tricky. In case of as_dict=True, executesql() uses the

[web2py] sessions and logout

2014-01-03 Thread Wonton
Hello everyone, Recently I suffered the problem with the number of session files growing very fast in my server. This worried me a lot because the server is a development environment with only 4 or 5 testers, so when the number of users is higher I guess I will have a big problem with this issu

[web2py] Re: request desktop site is not work when open web2py admin in mobile

2014-01-03 Thread 黄祥
hi dave, i'm sorry, i mean when i access to web2py server from mobile devices, e.g. access pythonanywhere.com from mobile devices. when i got the web2py app *.w2p on my email in my mobile i think i can get upload and install it to pythonanywhere.com from my mobile. best regards, stifan -- R

[web2py] Re: Authorization for Webhooks

2014-01-03 Thread Francisco Costa
I had a similar problem with a webook. In my case I read the HTTP POST with request.body.read() Chek it here: http://web2py.com/books/default/chapter/29/04/the-core?search=request.body.read%28%29 And this example: http://www.web2py.com/AlterEgo/default/show/197 On Sunday, February 13, 2011 11:

[web2py] Re: Virtual field for latitude and longitude from geometry field?

2014-01-03 Thread User
Didn't realize you could make a second query in a Virtual field but makes sense now that I see it. Although I'd rather not make the extra query (2 actually since longitude would need to do the same thing) so I guess I will just add latitude and longitude directly to my original select instead o

[web2py] Re: Happy New Year everybody!

2014-01-03 Thread Dave S
On Wednesday, January 1, 2014 2:06:30 PM UTC-8, Massimo Di Pierro wrote: > > Happy new year everybody, > > some good news: > 1) python is growing popularity > > https://sites.google.com/site/pydatalog/pypl/python-blog/pythonisthelanguageoftheyear > 2) there will be a web2py tutorial at PyCon. I wil

Re: [web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Brando
> > Version > > 2.8.2-stable+timestamp.2013.11.28.13.54.07 > (Running on Rocket 1.2.6, Python 2.7.3) > Also, I doubt it's relevant, but I'm using Sublime Text as my IDE. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source cod

Re: [web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Richard Vézina
Which version of web2py do you use? from gluon.custom_import import track_changes; track_changes(True) Have been broken during sometime... Richard On Fri, Jan 3, 2014 at 2:50 PM, Brando wrote: > Here is the test app. > > > > > > > On Friday, January 3, 2014 11:35:22 AM UTC-8, Anthony wrot

[web2py] Re: Waiting for Scheduler Task to Complete is Blocking Work?

2014-01-03 Thread Anthony
Maybe when the task is scheduled, either store the task ID in the session or return it to the browser. Then from the browser, make Ajax requests every x seconds to an action that checks the task status. When the task is complete, the browser can then reload the grid. Anthony On Friday, January

[web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Anthony
On Friday, January 3, 2014 2:22:42 PM UTC-5, Brando wrote: > > Anthony, I added the line to a model and it still doesn't work. Any other > thoughts? > Not sure. Did you restart? Maybe pack and attach a minimal app that demonstrates the problem. > Also, why is it not recommended for production

[web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Brando
Anthony, I added the line to a modeland it still doesn't work. Any other thoughts? Also, why is it not recommended for production? On Friday, January 3, 2014 8:26:13 AM UTC-8, Anthony wrote: > > It's the same with any Python module -- they only get loaded once on first > import. web2py does

[web2py] Re: request desktop site is not work when open web2py admin in mobile

2014-01-03 Thread Dave S
Stifan, your posts are normally easy to read, but this one has me confused. Those That Know What They Are Doing may have better understanding, but in the meantime you might try rewording your question. My best guess is that you want to run your server's admin app from a mobile device (e.g., p

[web2py] Re: Waiting for Scheduler Task to Complete is Blocking Work?

2014-01-03 Thread EW
Ah, that makes sense! But I still need help...the reason I want to use the scheduler is to have a worker do database inserts and simultaneously update an sql grid of the table being inserted into (as described in this question you've already seen https://groups.google.com/forum/#!topic/web2p

Re: [web2py] Re: Error in Custom Register Page in web2py

2014-01-03 Thread Akash Agrawall
true that... this one is better.. On Fri, Jan 3, 2014 at 9:59 PM, Anthony wrote: > No, it's better to set the readable and writable attributes to False if > you want particular fields to be excluded from the form. > > for fields in ['field1', 'field2', 'field3']: > db.auth_user[fiel

[web2py] Re: Waiting for Scheduler Task to Complete is Blocking Work?

2014-01-03 Thread Anthony
scheduler.queue_task() simply inserts a record into the scheduler_task table. However, assuming this code is part of an HTTP request, the insert won't get committed until the request is complete. Yet your code then includes a while loop that will not exit until after the insert (and after the t

[web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Brando
Actually, any changes made to my module file will not be reflected until i restart the web2py.app. On Friday, January 3, 2014 8:14:36 AM UTC-8, Brando wrote: > > I have the following code to insert a dictionary into my sqlite db from a > module. > > #!/usr/bin/env python > # -*- coding

[web2py] Re: Error in Custom Register Page in web2py

2014-01-03 Thread Anthony
No, it's better to set the readable and writable attributes to False if you want particular fields to be excluded from the form. for fields in ['field1', 'field2', 'field3']: db.auth_user[field].readable = db.auth_user[field].writable = False form = auth.register() Anthony On Fr

[web2py] Re: Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Anthony
It's the same with any Python module -- they only get loaded once on first import. web2py does include a feature to automatically re-load upon change, though not recommended for production. In a model file (before any imports): from gluon.custom_import import track_changes; track_changes(True)

[web2py] Inserting to db from module. Why do I need to keep restarting Web2py?

2014-01-03 Thread Brando
I have the following code to insert a dictionary into my sqlite db from a module. #!/usr/bin/env python # -*- coding: utf-8 -*- from gluon import current from gluon.dal import DAL, Field from gluon.sqlhtml import SQLFORM from gluon.validators import IS_NOT_EMPTY, IS_EMAIL, IS_LENGTH class Pars

[web2py] Waiting for Scheduler Task to Complete is Blocking Work?

2014-01-03 Thread EW
I'm having trouble figuring out how to determine when a scheduler task is done. My code/scheduler task work is working. But when I added this loop, it does not--when I go into the admin interface and look at the scheduler_task table, the task is not in the table at all. The printouts show th

Re: [web2py] Re: Happy New Year everybody!

2014-01-03 Thread Richard Vézina
Happy new year to all!! :) Richard On Fri, Jan 3, 2014 at 9:41 AM, Gael Princivalle wrote: > An happy new year also to you Massimo and to all web2pyer's in all other > the world. > > > Il giorno mercoledì 1 gennaio 2014 23:06:30 UTC+1, Massimo Di Pierro ha > scritto: > >> Happy new year everyb

[web2py] Re: Happy New Year everybody!

2014-01-03 Thread Gael Princivalle
An happy new year also to you Massimo and to all web2pyer's in all other the world. Il giorno mercoledì 1 gennaio 2014 23:06:30 UTC+1, Massimo Di Pierro ha scritto: > > Happy new year everybody, > > some good news: > 1) python is growing popularity > > https://sites.google.com/site/pydatalog/pyp

Re: [web2py] Re: web2py and SEO

2014-01-03 Thread Gael Princivalle
Hi Bruno. In a same page where you make translations, how can you manage meta informations for all languages ? With a if T.accepted_language you can set different values, but when you give your site to a tool like that : http://www.seoutility.com/it/tools/google/sitemap_generator.aspx it see onl

[web2py] Re: favicon problem

2014-01-03 Thread Gael Princivalle
Same cache problem also for me. Just replace .ico and .png files and test it in an anonymous browser window. Il giorno domenica 17 giugno 2012 12:20:54 UTC+2, Paolo Caruccio ha scritto: > > In my case was a cache problem. Below the solution worked for me: > > 1. below replacing files clear the c

[web2py] Re: Error in Custom Register Page in web2py

2014-01-03 Thread Akash Agrawall
Have to define all the attributes in custom form otherwise it won't run... wasn't doing the same. define it as hidden if you don't want user to see them. !! On Tuesday, December 31, 2013 5:54:34 PM UTC+5:30, Akash Agrawall wrote: > > Hie folks. When I click on submit button of th

Re: [web2py] Re: OT: movuca internal error on comment

2014-01-03 Thread Alan Etkin
> anyway I found that in spite of the error I got yesterday the comment has been already posted. Ok, this is because the comment is commited before the buggy notification feature starts :P. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/we

[web2py] web2py running en AppFog

2014-01-03 Thread José Antonio López Lorenzo
DEMO: http://web2py.eu01.aws.af.cm/ EXPLANATION: http://jallander.wordpress.com/2014/01/03/web2py-en-appfog/ SERVER: https://www.appfog.com/ -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2p

[web2py] Re: Grid back button for custom single view

2014-01-03 Thread Gael Princivalle
Yes, that's the fastest solution. I will tried first to call a different html page for the custom single record view page, instead of calling the same where I have the grid. Thanks a lot. Il giorno domenica 29 dicembre 2013 18:28:06 UTC+1, Niphlod ha scritto: > > your problem is architectural: y

Re: [web2py] Re: OT: movuca internal error on comment

2014-01-03 Thread Manuele Pesenti
Il 03/01/14 10:25, Alan Etkin ha scritto: > > > that's what I get trying to add a comment to a post of mine. > > > Manuele, can you please try to add the comment now? here it is: http://www.web2pyslices.com/slice/showcomment/1500 anyway I found that in spite of the error I got yesterday t

[web2py] SEO for multilingual web sites

2014-01-03 Thread Gael Princivalle
Hello all. I've put on line my first web2py website, thanks to all for help. It's native in English, with Italian translation. So I've got things like that: Controller: def products(): ... response.title = 'My web site' + ' -' + T('Products') ... And in my views I load text from db

[web2py] Re: GAE: defaults on "_tableobj"

2014-01-03 Thread Quint
I created an issue for this: https://code.google.com/p/web2py/issues/detail?id=1842 On Thursday, January 2, 2014 6:45:59 PM UTC+1, Quint wrote: > > Hello everybody, > > Happy New Year! > > I'm using GAE and sometimes a need to call some GAE datastore functions > directly. > > (For instance when

[web2py] question about SQLFORM.grid

2014-01-03 Thread Robert Bjornson
Hi all, I am a newcomer to web2py, and have what I hope is a simple beginner question. I am following the "mywiki" example in the getting started tutorial. In it, one can display all the documents for a page using this url: *http://127.0.0.1:8000/mywiki/default/documents/1* *The controller fo

[web2py] Re: OT: movuca internal error on comment

2014-01-03 Thread Alan Etkin
> that's what I get trying to add a comment to a post of mine. >> > Manuele, can you please try to add the comment now? > >> Sorry but I didn't find a contact form on web2pyslices site. >> > We should add at least a link to this list for posting issues. -- Resources: - http://web2py.com - h

[web2py] Re: Virtual field for latitude and longitude from geometry field?

2014-01-03 Thread Paolo Valleri
st_*() are db engine functions, you should query the db to get the output you are looking for. Given that, in your virtual field you should make a new query, something like that: Field.Virtual('latitude', lambda row: db(db.location.id == row.location.id). select(db.location.point.st_x()).first()

[web2py] Re: Possibly a problem with CAS redirection in v2.8.2

2014-01-03 Thread Tim Richardson
My issue 1840 is the same thing On Friday, 3 January 2014 04:02:03 UTC+11, Vinicius Assef wrote: > > I've just opened a ticket about it: > http://code.google.com/p/web2py/issues/detail?id=1841 > > On Tue, Dec 24, 2013 at 9:12 AM, Vinicius Assef > > > wrote: > > Anyone? > > > > On Fri, Dec 2