Re: [Twisted-Python] spawnProcess with timeout and same error handling on Unix and Windows

2014-09-03 Thread exarkun
On 05:17 pm, a...@roiban.ro wrote: On 3 September 2014 16:49, Adi Roiban wrote: Hi, If I call spawnProcess with a bad executable, on Unix the process will exit with exit code 1 while on Windows an OSError is raised. I am working on a multi-OS software and to make my life easier I ended up wit

Re: [Twisted-Python] spawnProcess with timeout and same error handling on Unix and Windows

2014-09-03 Thread Adi Roiban
On 3 September 2014 16:49, Adi Roiban wrote: > Hi, > > If I call spawnProcess with a bad executable, on Unix the process will > exit with exit code 1 while on Windows an OSError is raised. > > I am working on a multi-OS software and to make my life easier I ended > up with this hack inspired by _B

Re: [Twisted-Python] spawnProcess with timeout and same error handling on Unix and Windows

2014-09-03 Thread exarkun
On 03:49 pm, a...@roiban.ro wrote: Hi, If I call spawnProcess with a bad executable, on Unix the process will exit with exit code 1 while on Windows an OSError is raised. Ideally, these two implementations of the same interface would have the same error behavior in this case. In other words,

[Twisted-Python] spawnProcess with timeout and same error handling on Unix and Windows

2014-09-03 Thread Adi Roiban
Hi, If I call spawnProcess with a bad executable, on Unix the process will exit with exit code 1 while on Windows an OSError is raised. I am working on a multi-OS software and to make my life easier I ended up with this hack inspired by _BackRelay https://gist.github.com/adiroiban/bac493f00ce5e9