Message375782
It is a tutorial. The purpose of this part is documenting the bare except clause. It cannot be done without using a bare except in example.
There is nothing wrong with a bare except if it used properly (e.g. if the caught exception is reraised). In any case "except BaseException" is not any better, because it is equivalent to a bare except.
Note also that PR 21917 introduces an error: instead of printing the type of exception it prints the stringified exception itself (in some case it is an empty string). |
|
Date |
User |
Action |
Args |
2020-08-22 05:21:07 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, terry.reedy, docs@python, graingert |
2020-08-22 05:21:07 | serhiy.storchaka | set | messageid: <1598073667.18.0.308655935734.issue41576@roundup.psfhosted.org> |
2020-08-22 05:21:07 | serhiy.storchaka | link | issue41576 messages |
2020-08-22 05:21:07 | serhiy.storchaka | create | |
|