Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Ian Kelly
On Tue, Jul 24, 2012 at 1:32 PM, Paul Rubin wrote: > Dieter Maurer writes: >> I have only one vague idea: should something try to terminate the >> process, modules would start to lose their variables during shutdown. > > That happens all the time with multi-threaded programs, because the > shutdo

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Ian Kelly
On Tue, Jul 24, 2012 at 8:59 AM, Dieter Maurer wrote: > "ivdn...@gmail.com" writes: > >> I have a daemon process that runs for a considerable amount of time (weeks >> on end) without any problems. At some point I start getting the exception: >> >> Exception info: Traceback (most recent call last

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Paul Rubin
Dieter Maurer writes: > I have only one vague idea: should something try to terminate the > process, modules would start to lose their variables during shutdown. That happens all the time with multi-threaded programs, because the shutdown is happening concurrently with other threads doing stuff.

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Dieter Maurer
"ivdn...@gmail.com" writes: > I have a daemon process that runs for a considerable amount of time (weeks on > end) without any problems. At some point I start getting the exception: > > Exception info: Traceback (most recent call last): > File "scheduler.py", line 376, in applyrule > resul

Re: Daemon loses __file__ reference after a while

2012-07-24 Thread ivdn...@gmail.com
On Tuesday, July 24, 2012 2:29:19 PM UTC+2, Laszlo Nagy wrote: > On 2012-07-24 14:17, ivdn...@gmail.com wrote: > > Hello all, > > > > I have a deamon process that runs for some considerable time (weeks) > without any problems. At some point it starts throwing the following > exception: > > > >

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread ivdn...@gmail.com
On Tuesday, July 24, 2012 2:24:31 PM UTC+2, Ervin Hegedüs wrote: > hello, > > On Tue, Jul 24, 2012 at 04:48:42AM -0700, ivdn...@gmail.com wrote: > > Hello, > > > > I have a daemon process that runs for a considerable amount of time > (weeks on end) without any problems. At some point I start get

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Laszlo Nagy
If you use fork(), it drops all file descriptors, and creates new ones - may be then loss the __file__...? I don't think this is the case. He wrote that the process runs for weeks without problems, and code using __file__ is being executed all the time. -- http://mail.python.org/mailman/listi

Re: Daemon loses __file__ reference after a while

2012-07-24 Thread Laszlo Nagy
On 2012-07-24 14:17, ivdn...@gmail.com wrote: Hello all, I have a deamon process that runs for some considerable time (weeks) without any problems. At some point it starts throwing the following exception: File "/some/path/scheduler.py", line 376, in applyrule result = execrule(rule_co

Re: Daemon loses __file__ reference after a while.

2012-07-24 Thread Ervin Hegedüs
hello, On Tue, Jul 24, 2012 at 04:48:42AM -0700, ivdn...@gmail.com wrote: > Hello, > > I have a daemon process that runs for a considerable amount of time (weeks on > end) without any problems. At some point I start getting the exception: > > Exception info: Traceback (most recent call last): >

Daemon loses __file__ reference after a while

2012-07-24 Thread ivdn...@gmail.com
Hello all, I have a deamon process that runs for some considerable time (weeks) without any problems. At some point it starts throwing the following exception: File "/some/path/scheduler.py", line 376, in applyrule result = execrule(rule_code) File "/some/path/scheduler.py", line 521, in

Daemon loses __file__ reference after a while.

2012-07-24 Thread ivdn...@gmail.com
Hello, I have a daemon process that runs for a considerable amount of time (weeks on end) without any problems. At some point I start getting the exception: Exception info: Traceback (most recent call last): File "scheduler.py", line 376, in applyrule result = execrule(rule_code) File "s