python ignore whichever line that causes error and continue running the code after that line -


i understand try/except method. i'm trying is:

try:     some_func1() #potentially raises error     do_something_else() #error raised     continue_doing_something_else() #continues here after handling error except:     pass 

in above code, when error raised @ do_something_else(), error handled try statement exited.

what want python continue whatever code after line causes error. assuming error can happen anywhere in try statement can't wrap try/except around do_something_else() itself, there way in python?

what want (try restart) not possible in python. lisp can (http://www.gigamonkeys.com/book/beyond-exception-handling-conditions-and-restarts.html), , can implement in scheme using call/cc.


Comments

Popular posts from this blog

python - Selenium remoteWebDriver (& SauceLabs) Firefox moseMoveTo action exception -

html - How to custom Bootstrap grid height? -

transpose - Maple isnt executing function but prints function term -