Hacker News new | ask | show | jobs
by hathawsh 2463 days ago
Right. In Python, raising an exception is considered just as safe and normal as returning a value, so Python uses exceptions even for very common things like stopping iterations. IMHO a Python exception is quite similar to a Rust "Result::Err".