Created
September 7, 2020 11:01
-
-
Save Drvanon/e2f0eb2778752fef1ae7254b0b87fe83 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def outside_try(): | |
foo = None | |
try: | |
foo = load_foo() | |
except FooLoadingError: | |
return "Foo failed to load" | |
# Do all the things | |
return foo | |
def inside_try(): | |
try: | |
foo = load_foo() | |
# Do all the things | |
return foo | |
except FooLoadingError: | |
return "Foo failed to load" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment