I hope you’re joking. If anything, Rust makes error handling easier by returning them as values using the Result monad. As someone else pointed out, they literally used unwrap in their code, which basically means “panic if this ever returns error”. You don’t do this unless it’s impossible to handle the error inside the program, or if panicking is the behavior you want due to e.g. security reasons.
Even as an absolute amateur, whenever I post any Rust to the public, the first thing I do is to get rid of unwrap as much as possible, unless I intentionally want the application to crash. Even then, I use expect instead of unwrap to have better error logging. This is definitely the work of some underpaid intern.
Thallium_X@feddit.org 4 months ago
As a next step they should have wrapped everything in a true(while) loop so it automatically restarts and the program never dies
panda_abyss@lemmy.ca 4 months ago
Exactly,
while True: try: main(); except: pass;