Re: [web2py] Re: anyserver and scheduler

2013-03-16 Thread Manuele Pesenti
Il 15/03/13 20:22, Niphlod ha scritto: > no. the scheduler is supposed to run OUTSIDE the "watch" of a > webserver, of any kind. ok, many thanks Niphlod Cheers M. -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this gr

[web2py] Re: smartgrid: how to disable repeating parent ID in child record

2013-03-16 Thread Alex Glaros
Thanks Jason, but it only made the parent ID completely disappear from the child file, not keep the first instance of parent ID as desired I think I'm asking too much from smartgrid Alex On Wednesday, March 13, 2013 3:02:44 PM UTC-7, Jeison Dück wrote: > > Putting this, on controller - > > d

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Paolo valleri
Hi Niphlod, I am thinking that I do misunderstood the book because I put this line scheduler.queue_task(test_rest, period=10, repeats=0) in a model file, this means that I have re-scheduled my task times and times! Btw, which should be the best place to add a new task (beside using your plugin

[web2py] Re: smartgrid: how to disable repeating parent ID in child record

2013-03-16 Thread Alex Glaros
Hi Jason, my real fields are so different, I need a little help. Can you please tell me what does what so I can implement? E.g." (db.project.created_by==auth.user) << > did you try using query ? > > e.g. > query=(db.project.created_by==auth.user) & (db.project.is_active==True) > grid=SQLFORM.gri

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Niphlod
you should insert a new task if it's "connected" to an event in a controller. If you need to queue a recurring task one-time-only and is not controlled by some logic in your app, you should insert it using the appadmin On Saturday, March 16, 2013 8:16:38 AM UTC+1, Paolo valleri wrote: > >

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Niphlod
ps. I though "windows support is available from 1.9" meant that 1.9-rc2 had it. Retrying asap (PS: first build under windows in my entire life ^_^) On Saturday, March 16, 2013 5:44:32 AM UTC+1, Roberto De Ioris wrote: > > > > me neither. My attempts to build 1.9 rc2 under cygwin fail miserabl

[web2py] Re: Parent-child model form based on many sqlforms on one page

2013-03-16 Thread Niphlod
on the ajax/js side code a component and LOAD(ajax=True) multiple times with different parameters ? On Saturday, March 16, 2013 2:55:38 AM UTC+1, Tim Richardson wrote: > > I have an application with a parent-child data model where I think > sqlform.grid will be a frustrating user interface

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Niphlod
so. Build runs fine now. Something is missing or my cygwin installation (fresh one) is missing some bits https://www.dropbox.com/s/9u8xz0yhfjsed0e/uwsgi.txt -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Roberto De Ioris
> so. Build runs fine now. Something is missing or my cygwin > installation > (fresh one) is missing some bits > > https://www.dropbox.com/s/9u8xz0yhfjsed0e/uwsgi.txt you need to rebaseall the cygwin installation: http://cygwin.wikia.com/wiki/Rebaseall (smashed my head over that kind o

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Niphlod
oh. That took nearly 2 seconds (and was nice to know, thanks Roberto). Although I feel dirty in the process (guess being among the first ones kinda leads to "dirtyness"), now web2py is running on windows under uwsgi just fine! The second someone more skilled in cygwin related businesses publis

[web2py] Re: Parent-child model form based on many sqlforms on one page

2013-03-16 Thread Tim Richardson
On Saturday, 16 March 2013 19:11:13 UTC+11, Niphlod wrote: > > on the ajax/js side code a component and LOAD(ajax=True) multiple > times with different parameters ? Perhaps it is time for me learn about this :) The SQLFORM approach gives me all the SQLFORM validation and default widget

[web2py] Re: Parent-child model form based on many sqlforms on one page

2013-03-16 Thread Tim Richardson
On Saturday, 16 March 2013 20:29:55 UTC+11, Tim Richardson wrote: > > > > On Saturday, 16 March 2013 19:11:13 UTC+11, Niphlod wrote: >> >> on the ajax/js side code a component and LOAD(ajax=True) multiple >> times with different parameters >> > I watched a video tutorial about LOAD(ajax=Tr

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread David Marko
Can you share uwsgi binary please? Dne sobota, 16. března 2013 10:21:15 UTC+1 Niphlod napsal(a): > > oh. That took nearly 2 seconds (and was nice to know, thanks Roberto). > > Although I feel dirty in the process (guess being among the first ones > kinda leads to "dirtyness"), now web2py is runn

[web2py] Field('upload') : problem with file name

2013-03-16 Thread Loïc
Dear All, I have a problem with Field('upload). It seems that some file names produce an error in DAL. Let's take a "test" app to reproduce it. 1) A simple model : db = DAL('mysql://user:pass@myServer') db.define_table('file', Field('title', label=T('Title'), notnull=True), Field('file'

[web2py] Re: smartgrid: how to disable repeating parent ID in child record

2013-03-16 Thread 黄祥
query=(db.project.created_by==auth.user) & (db.project.is_active==True) is the query that check wheter the database table project is created by the current authenticate user *AND *the database table status is active i think if you want to show the database table project is created by the curren

[web2py] Re: smartgrid: how to disable repeating parent ID in child record

2013-03-16 Thread 黄祥
maybe my code is similar for you, please check : https://sugizo.pythonanywhere.com/task/default/task email : us...@gmail.com password : password email : us...@gmail.com password : password if you want i can share the code. in that webapps, i'm using task, maybe you can change it into database t

Re: [web2py] Bunch/Batch/Bulk insert Re-use db.define_table field definition in SQLFORM.factory() ?

2013-03-16 Thread 黄祥
i'm just trying the code myself but seems the result is not expected (no errors occured) e.g. *db.py* db.define_table('company', Field('company')) *default.py* def index(): inputs = [] for i in range(0,10): inputs.append(db.company.company.clone(name='%s_%s' % (db.company.com

[web2py] Re: Web2py 2.4.4

2013-03-16 Thread Annet
Massimo, I just checked, and the issues has been fixed, thanks. Kind regards, Annet. -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...

Re: [web2py] Bunch/Batch/Bulk insert Re-use db.define_table field definition in SQLFORM.factory() ?

2013-03-16 Thread Anthony
It's {{=form}}, not {{form}}. Anthony On Saturday, March 16, 2013 9:00:22 AM UTC-4, 黄祥 wrote: > > i'm just trying the code myself but seems the result is not expected (no > errors occured) > e.g. > *db.py* > db.define_table('company', > Field('company')) > > *default.py* > def index(): >

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Niphlod
I don't think that the binary that came out is runnable outside the cygwin env ... and I really don't know what are all the dll involved. Anyway, it's https://www.dropbox.com/s/gbrojey9ncj1e8i/uwsgi.exe On Saturday, March 16, 2013 10:48:53 AM UTC+1, David Marko wrote: > > Can you share uwsgi bin

Re: [web2py] Bunch/Batch/Bulk insert Re-use db.define_table field definition in SQLFORM.factory() ?

2013-03-16 Thread 黄祥
yeah my mistake i didn't notice, thanks for correcting me, anthony. i've already test the form is work fine, but it can't insert it into database. i've tried to add some code for that but the result is not expected (no error occured), here is the database table content, after i input and submit

[web2py] Re: Parent-child model form based on many sqlforms on one page

2013-03-16 Thread Niphlod
yes, and you can avoid specifying a different formname for each form you create in a single page. On Saturday, March 16, 2013 10:41:34 AM UTC+1, Tim Richardson wrote: > > > > On Saturday, 16 March 2013 20:29:55 UTC+11, Tim Richardson wrote: >> >> >> >> On Saturday, 16 March 2013 19:11:13 UTC+11,

Re: [web2py] Re: [OT] uWSGI quickstart for Web2Py (works on windows too)

2013-03-16 Thread Roberto De Ioris
> I don't think that the binary that came out is runnable outside the cygwin > env ... and I really don't know what are all the dll involved. Anyway, > it's > https://www.dropbox.com/s/gbrojey9ncj1e8i/uwsgi.exe Basically it should work in every system with the cygwin libraries used to compile th

[web2py] Field('upload') : problem with file name

2013-03-16 Thread wwwgong
You forgot to create the uploadfolder -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread dlypka
Is there a way to stretch (resize) each column? I also suggest using jqgrid, from plugin_wiki I suppose. jqgrid also can do tree-style parent-child expandable subrows which would be very nice to have. A row with a tree style plus sign would indicate the task finished (a child task_run row is ava

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Loïc
No, I have created the uploadforder. I can upload every files I want, excepted a file which is named *Audi A6 Avant 3.0 V6 TDI 240 DPF Quattro Tiptronic S Line (Break) 10_2009, Packs et options - Cote automobile - autoplus.fr.txt* regardless its content Le samedi 16 mars 2013 16:00:58 UTC+1, www

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread LightDot
If you're sure it's the file name, make some test cases, see what fails exactly and what doesn't... Usual suspects from the file name in question would be dots, parentheses, dashes, commas, spaces... I don't see any others. Or perhaps a hidden rogue character, like a space that isn't a space...

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Niphlod
nope Used jqgrid in the past and it's kind of a beast, but .to be totally fair, resizing columns on a table doesn't play very well with touch devices . Which column would you like to be resizable ? PS: a task can be completed and have no scheduler_run rows available cause the function

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread David Lypka
In my case, the result / return value columns need to be resizeable. On Sat, Mar 16, 2013 at 10:39 AM, Niphlod wrote: > nope Used jqgrid in the past and it's kind of a beast, but .to be > totally fair, resizing columns on a table doesn't play very well with touch > devices . > Which col

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread David Lypka
actually, scrollable at a minimum requirement. On Sat, Mar 16, 2013 at 10:39 AM, Niphlod wrote: > nope Used jqgrid in the past and it's kind of a beast, but .to be > totally fair, resizing columns on a table doesn't play very well with touch > devices . > Which column would you like to b

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Loïc
After some tries, I discovered that the problem is not in the characters. The problem is the file name length If filename length <= 76 characters it works If filename length *> 76 characters* the *error *ticket is raised... Le samedi 16 mars 2013 16:26:02 UTC+1, LightDot a écrit : > > If you'r

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Niphlod
uhm. can you send me a screenshot to identify the problem "in a visual way" ? if row_result is large I surely can't help (nor would any kind of "inline representation") but maybe with a tooltip we can circumvent the issue. On Saturday, March 16, 2013 4:48:52 PM UTC+1, dlypka wrote: > > actually,

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Niphlod
if **feels** strange cause file is stored with a computed hash did you spot the issue on the code while figuring out the name on the disk or in the part where the record gets stored in the table ? On Saturday, March 16, 2013 4:50:41 PM UTC+1, Loïc wrote: > > After some tries, I discovered t

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread David Lypka
I could use an outer join or some custom code to handle the no child row case. In my SolidTable view I simply display 2 tables. The first one is just the first task table and the second is just the inner join. It is adequate for the time being... My scheduled task executes a unix shell script an

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Niphlod
and you need to read on the screen a row with 2k characters (supposedly a lot of rows on the same page) ? cs_monitor is more meant to monitor the workers "administratively", not to show their results, the plugin can be "eased" for sure but it can't be a solution for all kinds of requirements.

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread David Lypka
How to breakpoint in the task? On Sat, Mar 16, 2013 at 11:06 AM, Niphlod wrote: > and you need to read on the screen a row with 2k characters (supposedly a > lot of rows on the same page) ? > cs_monitor is more meant to monitor the workers "administratively", not to > show their results, the plu

Re: [web2py] Re: Scheduler: new plugin cs_plugin_monitor

2013-03-16 Thread Niphlod
a little offtopic but http://pydev.org/manual_adv_remote_debugger.html -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com.

[web2py] how to save session right now?

2013-03-16 Thread RunSky ruan
I want to save the session right now ,because a function must exe for al long time, how to save it right now? -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Loïc
I think I have found the problem. It's not a web2py issue but a python issue on windows : in dal.py", line 9228 there is the following line : dest_file = open(pathfilename, 'wb') If the filename is too big, the hash pathfilename length is about 275 characters I found a thread on stackoverflow w

Re: [web2py] Re: Scheduler: debugger breakpoints

2013-03-16 Thread David Lypka
Well its a big time saver to know which debugger works in the task scenario, since it seems to be problematic / non obvious with at least one IDE. Thanks. On Sat, Mar 16, 2013 at 11:25 AM, Niphlod wrote: > a little offtopic but http://pydev.org/manual_adv_remote_debugger.html > > > -- > > ---

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Niphlod
that seems a bug. Unless you're forcing it, web2py should save a file in folder/tablename_field.somehash.originalextension i.e. whatever length the filename originally is, it gets stored with a somewhat "constant" filename length. Can you pack a minimal app to reproduce the issue ? On Saturd

[web2py] Re: Field('upload') : problem with file name

2013-03-16 Thread Niphlod
I was wrong. the first part of the "hash" is a uuid, the second is a base16 encoding of the original filename. Seems that you need some logic to cut down long files if you plan to host on Windows. http://web2py.com/books/default/chapter/29/07?search=uploads#Storing-the-original-filename -- --

[web2py] Re: how to save session right now?

2013-03-16 Thread Niphlod
every time a request ends, the session is savedwhat do you need exactly ? On Saturday, March 16, 2013 5:32:29 PM UTC+1, RunSky ruan wrote: > > I want to save the session right now ,because a function must exe for al > long time, > how to save it right now? > -- --- You received this mess

[web2py] Re: how to save session right now?

2013-03-16 Thread Anthony
Assuming session stored in files, something like this might work (haven't tried it): session._try_store_in_file(request, response) # store the session in the file session.forget(response) # unlock the session file so it can be opened by another request There's also session._try_store_in_db a

Re: [web2py] Bunch/Batch/Bulk insert Re-use db.define_table field definition in SQLFORM.factory() ?

2013-03-16 Thread Anthony
There is no form.vars.company -- it's form.vars.company_0, form.vars.company_1, etc. So: db.company.insert(company=form.vars['company_%s' % i]) Anthony On Saturday, March 16, 2013 9:27:11 AM UTC-4, 黄祥 wrote: > > yeah my mistake i didn't notice, thanks for correcting me, anthony. i've > already

Re: [web2py] Bunch/Batch/Bulk insert Re-use db.define_table field definition in SQLFORM.factory() ?

2013-03-16 Thread Richard Vézina
Good catch Anthony... @Steve it exactly what I have in mind, except in my case the form has to be generic for many differents tables, but if you only one table to bunch insert, that way it works fine... Notice, if you create more inputs then the number your users will need (not 3 records for inst

[web2py] 5th Manual typo p.83

2013-03-16 Thread Jarrod Wilcox
Page 83, view example should say session.counter rather than counter. -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com

[web2py] Create a pdf and attach it to a mail

2013-03-16 Thread jjg0
I started looking at the MyFPDF examples and I am able to make simple pdf's. I want to be able to make a pdf and attach it to an email. Here is a simple example to show what I am doing and where I get lost: def sample(): from gluon.contrib.pyfpdf import FPDF, HTMLMixin class My

[web2py] Re: Create a pdf and attach it to a mail

2013-03-16 Thread Alan Etkin
> > I started looking at the MyFPDF examples and I am able to make simple > pdf's. I want to be able to make a pdf and attach it to an > email. Here is a simple example to show what I am doing and where I get > lost: > If your app has write access to the filesystem (almost any environment ha

[web2py] Need to automatically update a SQLFORM grid if new records are inserted in table

2013-03-16 Thread Michael Ellis
I've got an application that accepts JSON test reports from remote systems and displays them in a SQLFORM grid with the most recent reports first. The controller and view for what the user sees is essentially the following: CONTROLLER def test_report_manage(): """ Controller for Reports pa

Re: [web2py] Need to automatically update a SQLFORM grid if new records are inserted in table

2013-03-16 Thread Ricardo Pedroso
On Sat, Mar 16, 2013 at 10:42 PM, Michael Ellis wrote: > I've got an application that accepts JSON test reports from remote systems > and displays them in a SQLFORM grid with the most recent reports first. The > controller and view for what the user sees is essentially the following: > > CONTROLL

Re: [web2py] Re: Not to open a can of worms ... about web2py.com

2013-03-16 Thread wwwgong
I like web2py especially with the recent makeover. However, the web2py logo is kind of plain, why not add some colors to the letters? I am no artist, but attached a draft design. Obviously we need a cute snake cartoon. On Friday, March 15, 2013 10:31:30 PM UTC-4, Richard wrote: > > Here what co

[web2py] Re: smartgrid: how to disable repeating parent ID in child record

2013-03-16 Thread Alex Glaros
thanks Steve but your example doesn't have the child detail records the way mine does, so it's a different example pythonanywhere host seems great I'll hold off on this problem till later much appreciated, Alex On Saturday, March 16, 2013 5:39:58 AM UTC-7, 黄祥 wrote: > > maybe my code is simil