Ganesh Pal <ganesh1...@gmail.com> writes:

> 1. Can we have if else with in a try except block

What result do you get when running that code? What empirical reason do
you have to think it would work or not work?

> 2. How can the above code be improved

The following sequence of statements::

    raise Exception("/nfs_mount is not mounted. Dataset create failed !!!")
    return False

do not make sense. The ‘return‛ statement will never be reached. So your
intent must be something other than what is expressed by that code.

-- 
 \     “Do unto others twenty-five percent better than you expect them |
  `\      to do unto you. (The twenty-five percent is [to correct] for |
_o__)                            error.)” —Linus Pauling's Golden Rule |
Ben Finney

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to