[web2py] Re: uwsgi: strange messages

2015-02-03 Thread Niphlod
the " from operator import _compare_digest as compare_digest" is documented on the interwebs just google it... "standard issues" are playing with different versions of python in the same server. the "how do I run it not from root" well. Don't start uwsgi while logged in as root ! You sta

Re: [web2py] Re: ckeditor : how to make read only, how to remove the toolbar in a dynamic way

2015-02-03 Thread Serge Bourgeois
Thanks for your response. The solution I'm looking for should preserve the way ckeditor displays the text. Based on you idea, I tried this in my controller: db.my_table.my_field.represent = lambda value, row: ckeditor.widget(db.my_table.my_field, value, **{'_name':'my_field_row_%s' % row.id })

Re: [web2py] Re: ckeditor : how to make read only, how to remove the toolbar in a dynamic way

2015-02-03 Thread Serge Bourgeois
If I could find a way to add a way to change, in the view this : > Thanks for your response. > > The solution I'm looking for should preserve the way ckeditor displays the > text. > > Based on you idea, I tried this in my controller: > > db.my_table.my_field.represent = lambda value, row: > cked

[web2py] Re: insecure string pickle

2015-02-03 Thread Leonel Câmara
Did you compile the admin app on the same computer this is running in now? -- 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

Re: [web2py] Re: Handling (2006, 'MySQL server has gone away') from Scheduler, pythonanywhere

2015-02-03 Thread vld...@gmail.com
sometimes this error (2006, 'MySQL server has gone away') happens when parameter 'max_allowed_packet" is too small. $ sudo vim /etc/mysql/my.cnf # goto the [mysqld] section [mysqld] ... max_allowed_packet=8M <<-- change this with, for example, 500M Hope this can help you Vladyslav Kozlovsk

Re: [web2py] How to mimic routes.py with nginx

2015-02-03 Thread al ex
I have commented the following 4 directives in my server declaration, that now looks like as below, and it seems to work better. open_file_cache max=1000 inactive=20s; open_file_cache_valid30s; open_file_cache_min_uses 2; open_file_cache_errors on; -

Re: [web2py] How to mimic routes.py with nginx

2015-02-03 Thread Michele Comitini
Where's the /AAA location directive? If you want to cache you can try the uwsgi directives : http://nginx.org/en/docs/http/ngx_http_uwsgi_module.html#uwsgi_cache The rest seems ok. 2015-02-03 13:22 GMT+01:00 al ex : > I have commented the following 4 directives in my server declaration, that > no

[web2py] question, kind of general

2015-02-03 Thread lucas
hey everyone, so i wrote some code that does a bunch of web scraping and i just threw the code in a regular controller so i can output at different stages of development so i can trace the outputs for the next stage. now i have to code running and it can run for days on end at full CPU capacit

[web2py] args typed in by hand into URL address window

2015-02-03 Thread Alex Glaros
how to catch args typed in by user into address window example of URL at top of browser: view_user_profile/4 user goes to address window and changes 4 to 1 so now, #1 person's data appears instead of #4 person view_user_profile/1 what is the syntax for capturing that URL arg typed in by user?

Re: [web2py] args typed in by hand into URL address window

2015-02-03 Thread Richard Vézina
request.args(0)... If user input 4 instead of 1 and access the page you can get the args the same way you do it if you pass args value programmatically... Is you question to know how you can avoid that or kind of double check if programmatically passed args doens't change? If so, maybe it is not

Re: [web2py] args typed in by hand into URL address window

2015-02-03 Thread Richard Vézina
Or, if you just want to check if args passed has been change you can store the programmatically passed args in session and ckeck in session before process form or accessed page Richard On Tue, Feb 3, 2015 at 4:20 PM, Richard Vézina wrote: > request.args(0)... > > If user input 4 instead of

Re: [web2py] args typed in by hand into URL address window

2015-02-03 Thread Richard Vézina
Ok, read very fast... didn't understand the context... For user_profile kind of stuff, I would go with permission... You create a role that has access to user_profile_update_form, like, manage_user group... And you have 2 functions/pages one that only show user profile data... You can filter what

[web2py] Re: question, kind of general

2015-02-03 Thread Leonel Câmara
You should use the scheduler for this. Moving it to a module won't solve the problem. -- 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 m

Re: [web2py] args typed in by hand into URL address window

2015-02-03 Thread Alex Glaros
thanks Richard, all of this is very helpful. Will use it all now at at least later. I think arg that I want is "raw_args", but what is syntax for getting it? if I type {{=response.raw_args}} I get "None" when raw_args in response.toolbar displays as "4" thanks Alex -- Resources: - http:

Re: [web2py] args typed in by hand into URL address window

2015-02-03 Thread Alex Glaros
never mind, found it: {{=request.raw_args}} thanks Alex -- 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 because you are subscr

[web2py] Re: How can I change a form so that the Enter key is disabled for "Submit"

2015-02-03 Thread Tom Stratton
Thanks - I found several methods on SO that involved manipulation of the OUTPUT from web2py that gets rendered in the browser. Implemented a solution that was very specific to the forms that I want to have filled in. I had hoped for a web2py specific way to manage the submit button behavior be

[web2py] Re: Groupby year on date field

2015-02-03 Thread Moiz Nagpurwala
Hello, Sorry to bug you all, but I am still stuck with this year groupby issue. I am fairly new to Python and web2py. Any suggestions or alternative method to achieve the result is highly appreciated. Thank you all. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] Re: Handling (2006, 'MySQL server has gone away') from Scheduler, pythonanywhere

2015-02-03 Thread Ian Ryder
No, there's nothing in there for now - just wanted to catch the right place. Is there a straight-forward way to reconnect? As mentioned, it's dropping out with no activity other than the scheduler heartbeat running and once it drops out, it stays dropped out so the whole app is effectively un

[web2py] Debian 7 with Lighttpd + web2py setup

2015-02-03 Thread Jon M.
Peaceful greetings Google Group Members and Mr. Di Pierro. First of all, thanks to all of you, web2py dev team, group members,for giving us the power of deploying with such a complete python web framework. I can imagine the heavy load of work behind from its beginning, to present day. The thin

[web2py] Re: Submit current form prior to logout?

2015-02-03 Thread lillian
I'm already handling my own validation so I can sanitize and do the right thing as needed. I'm mostly concerned about preserving user changes in cases where they might reasonably expect them to be persisted. Along those lines, since there is no "login expired" event (as I understand it) there

[web2py] https only on admin

2015-02-03 Thread Juozas Masiulis
For certain reasons I could not use https for my entire website. I load content from external domains through javascript, which I do not controll, and those scripts get blocked by the browser. I would like to use https only on admin, and I can get apache to redirect only admin to https by usin

[web2py] Re: uwsgi: strange messages

2015-02-03 Thread Martin Weissenboeck
You are right, there is a lot of entries about "from operator..." and I have tried some proposlas, but without success. Therefore I postet my question here. Anyway, your hints was helpful - thank you: it seems that there are diffenent libraries "python2.7": I wanted to use Python 2.7.9, but uwsgi