Re: how to terminate an external program after timeout?

2010-09-29 Thread Christian Maeder
Hi, thanks for pointing this out. Am 29.09.2010 06:47, schrieb Andrés Sicard-Ramírez: > Hi Christian, > > On Thu, Sep 9, 2010 at 4:35 AM, Christian Maeder > wrote: >> Hi, >> >> we call from our haskell application the metis prover via >> >> System.Process.readProcessWithExitCode "metis" filena

Re: how to terminate an external program after timeout?

2010-09-28 Thread Andrés Sicard-Ramírez
Hi Christian, On Thu, Sep 9, 2010 at 4:35 AM, Christian Maeder wrote: > Hi, > > we call from our haskell application the metis prover via > >  System.Process.readProcessWithExitCode "metis" filename "" > > However, we are not able to get rid of this process if metis does not > terminate by itself

Re: how to terminate an external program after timeout?

2010-09-14 Thread Edward Z. Yang
A possible cute solution would be to ulimit the processes permitted cpu time. Cheers, Edward ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Re: how to terminate an external program after timeout?

2010-09-13 Thread Simon Marlow
On 09/09/2010 17:18, Christian Maeder wrote: David Peixotto schrieb: On Sep 9, 2010, at 6:37 AM, Simon Marlow wrote: On 09/09/2010 10:39, Christian Maeder wrote: Christian Maeder schrieb: Hi, we call from our haskell application the metis prover via System.Process.readProcessWithExitCode

Re: how to terminate an external program after timeout?

2010-09-10 Thread Brandon S Allbery KF8NH
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 9/10/10 04:59 , Christian Maeder wrote: > Brandon S Allbery KF8NH schrieb: >> On 9/9/10 05:35 , Christian Maeder wrote: >>> System.Process.readProcessWithExitCode "metis" filename "" >> >> If all else fails, there's: >> >> sh -c '(sleep 120; kill -

Re: how to terminate an external program after timeout?

2010-09-10 Thread Christian Maeder
Brandon S Allbery KF8NH schrieb: > On 9/9/10 05:35 , Christian Maeder wrote: >> System.Process.readProcessWithExitCode "metis" filename "" > > If all else fails, there's: > > sh -c '(sleep 120; kill -TERM $$ >/dev/null 2>&1) & exec metis' Yes, I've considered something like this, too. It does n

Re: how to terminate an external program after timeout?

2010-09-09 Thread Brandon S Allbery KF8NH
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 9/9/10 05:35 , Christian Maeder wrote: > System.Process.readProcessWithExitCode "metis" filename "" If all else fails, there's: sh -c '(sleep 120; kill -TERM $$ >/dev/null 2>&1) & exec metis' which makes the shell deal with timeouts for you. (A

Re: how to terminate an external program after timeout?

2010-09-09 Thread Christian Maeder
David Peixotto schrieb: > On Sep 9, 2010, at 6:37 AM, Simon Marlow wrote: > >> On 09/09/2010 10:39, Christian Maeder wrote: >>> Christian Maeder schrieb: Hi, we call from our haskell application the metis prover via System.Process.readProcessWithExitCode "metis" filename

Re: how to terminate an external program after timeout?

2010-09-09 Thread David Peixotto
On Sep 9, 2010, at 6:37 AM, Simon Marlow wrote: > On 09/09/2010 10:39, Christian Maeder wrote: >> Christian Maeder schrieb: >>> Hi, >>> >>> we call from our haskell application the metis prover via >>> >>> System.Process.readProcessWithExitCode "metis" filename "" >>> >>> However, we are not a

Re: how to terminate an external program after timeout?

2010-09-09 Thread Simon Marlow
On 09/09/2010 10:39, Christian Maeder wrote: Christian Maeder schrieb: Hi, we call from our haskell application the metis prover via System.Process.readProcessWithExitCode "metis" filename "" However, we are not able to get rid of this process if metis does not terminate by itself. In parti

Re: how to terminate an external program after timeout?

2010-09-09 Thread Christian Maeder
Christian Maeder schrieb: > Hi, > > we call from our haskell application the metis prover via > > System.Process.readProcessWithExitCode "metis" filename "" > > However, we are not able to get rid of this process if metis does not > terminate by itself. In particular, wrapping this call into a

how to terminate an external program after timeout?

2010-09-09 Thread Christian Maeder
Hi, we call from our haskell application the metis prover via System.Process.readProcessWithExitCode "metis" filename "" However, we are not able to get rid of this process if metis does not terminate by itself. In particular, wrapping this call into a System.Timeout.timeout does not work. Any