[web2py] matplotlib passing parameters from the view

2016-05-05 Thread Paolo Amboni
I'm trying to build a single function (in a controller) that generate different matplotlib graph.. So the function that generate the stream works fine: *def grafico*(title='title',xlab='x',ylab='y' data= ): fig=Figure() return stream.getvalue() the function that call the

[web2py] Re: matplotlib passing parameters from the view

2016-05-05 Thread Paolo Amboni
I stored the id in a session variable and it works fine!! But why the URL helper didn't send the args to the function? Il giorno giovedì 5 maggio 2016 09:36:32 UTC+2, Paolo Amboni ha scritto: > > I'm trying to build a single function (in a controller) that generate > different matplotlib graph..

[web2py] Re: matplotlib passing parameters from the view

2016-05-05 Thread Niphlod
there's a problem in your syntax. it's usually URL('blabla', args=[], vars=dict()) while your code reports args=[..., dict=()] On Thursday, May 5, 2016 at 9:53:44 AM UTC+2, Paolo Amboni wrote: > > I stored the id in a session variable and it works fine!! > But why the URL helper didn't send the

[web2py] Re: A basic problem about threading and time consuming function...

2016-05-05 Thread Mirek Zvolský
Yes. I run with scheduler already. It is really nice and great ! Going away from the ajax solution it was easy and there was almost no problem. (I have very easy parameters for the task and I return nothing, just I save into db.) The result code is cleaner (one task starting call instead of rende

[web2py] Re: db is not defined in other model files

2016-05-05 Thread Vic Ding
The issue is gone magically. This happened before, the same issue come and go. I tried to add/edit db files both locally (from web UI) and externally (PyCharm on my laptop through SSH sync), both worked fine. One other issue is I have db.py, db1.py and test_list.py as model files. In test_lis

[web2py] Re: Strange trouble with password reset

2016-05-05 Thread Kirill Shatalaev
I've found a trouble: empty translation string. But I did not edit translations. Is it a bug? -- 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 receive

[web2py] Re: db is not defined in other model files

2016-05-05 Thread Mirek Zvolský
alphabetical order ? Will print 'db.py' < 'my_list.py' print True in that environment? And I don't know what web2py uses for alphabetical sorting of models. Try add print "db" and print "my_list" into that models to see if "my_list" really starts later. If it is well, cannot be db variable delet

[web2py] Re: db is not defined in other model files

2016-05-05 Thread Mirek Zvolský
Models run in alphabetical order. You should earlier define tables with primary keys for joins, and later tables with foreign keys of such joins. However if this is not possible, there is an alternative syntax for foreign keys which will help: Use 'reference joinedtable' instead of db.joinedtable

[web2py] Re: db is not defined in other model files

2016-05-05 Thread Vic Ding
Hi Mirek, Thanks for your kind help. I will look again into the book. On Thursday, May 5, 2016 at 4:00:02 PM UTC+2, Mirek Zvolský wrote: > > Models run in alphabetical order. > > You should earlier define tables with primary keys for joins, > and later tables with foreign keys of such joins. > >

[web2py] Re: db is not defined in other model files

2016-05-05 Thread Mirek Zvolský
I'm sorry, I read to late that you already use 'reference...' So back to previous: Add some printing or logging to see the order how the models really fire. Dne čtvrtek 5. května 2016 16:00:02 UTC+2 Mirek Zvolský napsal(a): > > Models run in alphabetical order. > > You should earlier define tabl

[web2py] Re: A basic problem about threading and time consuming function...

2016-05-05 Thread Mirek Zvolský
Debian/nginx/systemd deployment: I made scheduler working with help: https://groups.google.com/d/msg/web2py/eHXwines4o0/i3WqDlKjCQAJ and https://groups.google.com/d/msg/web2py/jFWNnz5cl9U/UpBSkxf4_2kJ Thank you very much Niphlod, Michael M, Brian M Dne čtvrtek 5. května 2016 13:06:04 UTC+2 Mi

[web2py] Re: Not seeing logging.error messages in nginx error_log

2016-05-05 Thread Dave S
On Wednesday, May 4, 2016 at 7:46:09 PM UTC-7, Chris Guest wrote: > > Hi DaveS, > > So to clarify when I used mod_wsgi & apache I used to get logging.error > messages saved into my apache error.log . > Now that I use uwsgi & nginx this doesn't happen. > I am not sure what your answer means as I

[web2py] Re: Enabling Unicode characters in URL

2016-05-05 Thread Kenneth
Just filed an issue. thank you, Leonel. Is there any interim solution to this problem? On Wednesday, May 4, 2016 at 2:31:17 PM UTC-4, Leonel Câmara wrote: > > For functions, specially since in python 2 the identifiers must be ascii. > If percent encoded args don't work then that's actually a bu

[web2py] Re: matplotlib passing parameters from the view

2016-05-05 Thread Paolo Amboni
Same problem! the args and var are not passed to the receiving function in this specific case. (I tried both args and vars alone first). With session all works fine. I find very complex the way web2py handle matplotlib plots. Is there other plotting library that better integrate in web2py framewo