Skip to content

Commit

Permalink
[Fix] Replace finally statement by except BaseException to suppress all
Browse files Browse the repository at this point in the history
exceptions

Co-authored-by:  Irit Katriel <iritkatriel@users.noreply.github.com>
  • Loading branch information
fjosw and iritkatriel committed Nov 3, 2024
1 parent 1895521 commit 32260b5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions autograd/wrap_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ def _wraps(f):
try:
f.__name__ = namestr.format(fun=get_name(fun), **kwargs)
f.__doc__ = docstr.format(fun=get_name(fun), doc=get_doc(fun), **kwargs)
except BaseException:
pass
finally:
return f

Expand Down

0 comments on commit 32260b5

Please sign in to comment.