Re: exception should not stop program.

2017-10-07 Thread MRAB
On 2017-10-07 17:38, Prabu T.S. wrote: I would like to continue to second function invocation "checkServiceStatus('AdobeARMservice')" even if the first checkServiceStatus('Tomcat9') has any exception.Please advice.Second function invocation not getting executed if any exception occurs in

Re: exception should not stop program.

2017-10-07 Thread Grant Edwards
On 2017-10-07, Jorge Gimeno wrote: > Catching all exceptions in a try-except block is almost always a bad > idea. Catching it and ignoring it as the OP was doing (or assuming it's some particular exception) certainly is. If you know (or suspect) that stderr isn't going anywhere that it will be

Re: exception should not stop program.

2017-10-07 Thread Jorge Gimeno
Catching all exceptions in a try-except block is almost always a bad idea. You can't tell the difference between an exception that you are looking to handle and an exception that should cause your program to crash and burn (because something is wrong). It's best to catch a specific exception. What

Re: exception should not stop program.

2017-10-07 Thread Prabu T.S.
On Saturday, October 7, 2017 at 12:38:11 PM UTC-4, Prabu T.S. wrote: > I would like to continue to second function invocation > "checkServiceStatus('AdobeARMservice')" even if the first >checkServiceStatus('Tomcat9') has any exception.Please advice.Second > function invocation not getting e

exception should not stop program.

2017-10-07 Thread Prabu T.S.
I would like to continue to second function invocation "checkServiceStatus('AdobeARMservice')" even if the first checkServiceStatus('Tomcat9') has any exception.Please advice.Second function invocation not getting executed if any exception occurs in first.Please advice. import psutil def