[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Marian
Thank you Niphlod for the slice. :)

But sadly it's not working for me. The problem is somehow my application 
and not nssm. If I define a scheduler in the welcome app it works.
In my app even a blank scheduler function fails.
In scheduler.py I found a check on WEB2PY_PATH, so I set it but without 
effect
I tried to remove all dependencies from custom modules without effect.

I think it fails in gluon.shell. What could cause this issue? I am not 
trying to do anny fancy stuff. ;)

if import_models:
try:
run_models_in(environment)
except RestrictedError, e:
sys.stderr.write(e.traceback + '\n')
sys.exit(1)



On Saturday, April 6, 2013 9:37:56 PM UTC+2, Brian M wrote:

 Did you get it working? If not I can check how I did it on my server later 
 today 

 On Friday, April 5, 2013 7:35:15 AM UTC-5, Marian wrote:

 Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

 gluon.shell line 137: sys.exit(1).

 When I try to restart the service, I don't get new failed tasks, so I 
 cannot say where this specific one came from.




 On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I hadn't 
 any problems a few months back, but I'll recheck for sure and post here or 
 on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest 
 for service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Niphlod
If a scheduler in the welcome app works, I'm quite sure (90%, give or take) 
that the problem lies in your app code

the point is: your scheduler doesn't work as a service cause as soon as 
it's started it dies or because while running all task fail ?


On Monday, April 8, 2013 9:28:30 AM UTC+2, Marian wrote:

 Thank you Niphlod for the slice. :)

 But sadly it's not working for me. The problem is somehow my application 
 and not nssm. If I define a scheduler in the welcome app it works.
 In my app even a blank scheduler function fails.
 In scheduler.py I found a check on WEB2PY_PATH, so I set it but without 
 effect
 I tried to remove all dependencies from custom modules without effect.

 I think it fails in gluon.shell. What could cause this issue? I am not 
 trying to do anny fancy stuff. ;)

 if import_models:
 try:
 run_models_in(environment)
 except RestrictedError, e:
 sys.stderr.write(e.traceback + '\n')
 sys.exit(1)



 On Saturday, April 6, 2013 9:37:56 PM UTC+2, Brian M wrote:

 Did you get it working? If not I can check how I did it on my server 
 later today 

 On Friday, April 5, 2013 7:35:15 AM UTC-5, Marian wrote:

 Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

 gluon.shell line 137: sys.exit(1).

 When I try to restart the service, I don't get new failed tasks, so I 
 cannot say where this specific one came from.




 On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I 
 hadn't any problems a few months back, but I'll recheck for sure and post 
 here or on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest 
 for service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Marian
I think you are right, it has something to do with the application itself. 
It dies directly on startup with exit code 1. The scheduler works when it 
is started in command line, so I think there is a problem with the 
environment or something like that.


On Monday, April 8, 2013 9:41:38 AM UTC+2, Niphlod wrote:

 If a scheduler in the welcome app works, I'm quite sure (90%, give or 
 take) that the problem lies in your app code

 the point is: your scheduler doesn't work as a service cause as soon as 
 it's started it dies or because while running all task fail ?


 On Monday, April 8, 2013 9:28:30 AM UTC+2, Marian wrote:

 Thank you Niphlod for the slice. :)

 But sadly it's not working for me. The problem is somehow my application 
 and not nssm. If I define a scheduler in the welcome app it works.
 In my app even a blank scheduler function fails.
 In scheduler.py I found a check on WEB2PY_PATH, so I set it but without 
 effect
 I tried to remove all dependencies from custom modules without effect.

 I think it fails in gluon.shell. What could cause this issue? I am not 
 trying to do anny fancy stuff. ;)

 if import_models:
 try:
 run_models_in(environment)
 except RestrictedError, e:
 sys.stderr.write(e.traceback + '\n')
 sys.exit(1)



 On Saturday, April 6, 2013 9:37:56 PM UTC+2, Brian M wrote:

 Did you get it working? If not I can check how I did it on my server 
 later today 

 On Friday, April 5, 2013 7:35:15 AM UTC-5, Marian wrote:

 Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

 gluon.shell line 137: sys.exit(1).

 When I try to restart the service, I don't get new failed tasks, so I 
 cannot say where this specific one came from.




 On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I 
 hadn't any problems a few months back, but I'll recheck for sure and 
 post 
 here or on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest 
 for service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Niphlod
are you playing with signals by any chance ?

-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Marian
I don't use signals, but I found the problem...

I linked my application via hardlink into the web2py applications folder so 
I can work with aptana studio and don't have to mess around with deploying 
everytime I change something.
I guess I need another way to separate web2py and the applications. Maybe 
you have a best practise for this?

Sorry for the troubles ;)

On Monday, April 8, 2013 10:25:34 AM UTC+2, Niphlod wrote:

 are you playing with signals by any chance ?



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-08 Thread Marian
Hardlinking the whole applications folder into web2py seems to work...

On Monday, April 8, 2013 10:36:40 AM UTC+2, Marian wrote:

 I don't use signals, but I found the problem...

 I linked my application via hardlink into the web2py applications folder 
 so I can work with aptana studio and don't have to mess around with 
 deploying everytime I change something.
 I guess I need another way to separate web2py and the applications. Maybe 
 you have a best practise for this?

 Sorry for the troubles ;)

 On Monday, April 8, 2013 10:25:34 AM UTC+2, Niphlod wrote:

 are you playing with signals by any chance ?



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-06 Thread Brian M
Did you get it working? If not I can check how I did it on my server later 
today 

On Friday, April 5, 2013 7:35:15 AM UTC-5, Marian wrote:

 Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

 gluon.shell line 137: sys.exit(1).

 When I try to restart the service, I don't get new failed tasks, so I 
 cannot say where this specific one came from.




 On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I hadn't 
 any problems a few months back, but I'll recheck for sure and post here or 
 on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
 service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-05 Thread Marian
I dug around in the event log and found:

Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
service web2py_scheduler_imagecontest4 in C:\Python27\.

Program C:\Python27\pythonw.exe for service web2py_scheduler_imagecontest4 
exited with return code 1.

Killing process tree of process 7296 for service 
web2py_scheduler_imagecontest4 with exit code 1

The scheduler works when used directly with python.

-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-05 Thread Niphlod
As soon as I get home I'll make screenshot of the configs  I hadn't any 
problems a few months back, but I'll recheck for sure and post here or on 
web2pyslices.com the steps involved.

On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
 service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service web2py_scheduler_imagecontest4 
 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.


-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-05 Thread Marian
That would be awesome. Thanks for the great work! :)

On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I hadn't 
 any problems a few months back, but I'll recheck for sure and post here or 
 on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
 service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-05 Thread Marian
Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

gluon.shell line 137: sys.exit(1).

When I try to restart the service, I don't get new failed tasks, so I 
cannot say where this specific one came from.




On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I hadn't 
 any problems a few months back, but I'll recheck for sure and post here or 
 on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
 service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.




[web2py] Re: nssm scheduler seems to be a nobrainer...

2013-04-05 Thread Niphlod
that should be it 
http://www.web2pyslices.com/slice/show/1614/nssm-webserver-and-scheduler-as-services-in-windows-oses

On Friday, April 5, 2013 2:35:15 PM UTC+2, Marian wrote:

 Hm maybe I have a hint, I found a failed entry in db.scheduler_run:

 gluon.shell line 137: sys.exit(1).

 When I try to restart the service, I don't get new failed tasks, so I 
 cannot say where this specific one came from.




 On Friday, April 5, 2013 1:36:37 PM UTC+2, Marian wrote:

 That would be awesome. Thanks for the great work! :)

 On Friday, April 5, 2013 12:46:36 PM UTC+2, Niphlod wrote:

 As soon as I get home I'll make screenshot of the configs  I hadn't 
 any problems a few months back, but I'll recheck for sure and post here or 
 on web2pyslices.com the steps involved.

 On Friday, April 5, 2013 11:34:30 AM UTC+2, Marian wrote:

 I dug around in the event log and found:

 Started C:\Python27\pythonw.exe D:\web2py\web2py.py -K imagecontest for 
 service web2py_scheduler_imagecontest4 in C:\Python27\.

 Program C:\Python27\pythonw.exe for service 
 web2py_scheduler_imagecontest4 exited with return code 1.

 Killing process tree of process 7296 for service 
 web2py_scheduler_imagecontest4 with exit code 1

 The scheduler works when used directly with python.



-- 

--- 
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://groups.google.com/groups/opt_out.