4 ms·
> The problem is that sometimes in Python exceptions can be used for control flow, or for things that are reasonably common. Using exceptions for control flow
by stevesimmons 3y ago
> The problem is that sometimes in Python exceptions can be used for control flow, or for things that are reasonably common.
Using exceptions for control flow is, imo, fine within a single function (e.g. for x in y: try: blah except KeyError: continue).
Using exceptions for control flow across function boundaries seems a recipe for confusion, unless very clearly documented.