On Fri, Jun 18, 2021 at 3:42 AM Stephen J. Turnbull firstname.lastname@example.org wrote:
Chris Angelico writes:
But logically, there is a significant difference between putting code inside the except block, and having "except X: pass" and then putting code after. Code should be written the way it's meant to be, not the way that happens to work.
Technical point: doesn't this apply to your suggestion of embedding it in a loop as well?
Yes, it does, which is why I expressed that hesitation. I can't say for sure whether, as a matter of programmer intent, it should be written one way or the other.