79650030

Date: 2025-06-02 16:50:02
Score: 1.5
Natty:
Report link

According to the documentation:

https://docs.python.org/3/reference/compound_stmts.html#the-try-statement

It is an expected behavior as:

If the finally clause executes a return, break or continue statement, the saved exception is discarded:

def f():
...     try:
...         1/0
...     finally:
...         return 42
...
>>> f()
42
Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Wuelfhis Asuaje