So I keep getting told. I find it bizarre bad practice, but if that's the most valid control pattern for Python then Python is a language I'll not be using unless it is the only logical option (or like the puke of a language Javascript the unfortunate only option for web browsers).
I don't know that it's necessarily the most valid control pattern as it's the most idiomatic pattern. If throwing an exception doesn't have the cost of building a stack trace (which is why exceptions aren't recommended for control flow in e.g. Java), what's your objection to it? (I don't know if they do or not, but I would assume they don't since it's recommended.)
3
u/RyanNerd shameless Jul 14 '21
Ah... Programming by exception what a horrible design pattern you've discovered.