Message410057
Andre:
You mention that user-defined exceptions should inherit from Exception. This is totally right and explicitly stated just a bit later in 8.6 on the same page of the tutorial. I think this perfectly covers this concern .
However, the paragraph I refer to explains the raise statement and as stated in the reference, the raise statement must be followed by a class or instance derived from BaseException. Thus, I think it would just be accurate and people reading on don't stumble over this difference as I did.
Regarding the mentioned wildcard: I think it wouldn't be a real wildcard anymore if it didn't catch ALL exceptions. Anyway the tutorial states that it needs to be used with extreme caution and the example re-raises the error.
Irit:
Yes I am happy provide a patch. I would also correct the other two issues you mentioned. |
|
Date |
User |
Action |
Args |
2022-01-08 00:04:17 | gtitze | set | recipients:
+ gtitze, aroberge, docs@python, sobolevn, iritkatriel |
2022-01-08 00:04:17 | gtitze | set | messageid: <1641600257.06.0.126247586525.issue46291@roundup.psfhosted.org> |
2022-01-08 00:04:17 | gtitze | link | issue46291 messages |
2022-01-08 00:04:16 | gtitze | create | |
|