Hacker News new | past | comments | ask | show | jobs | submit login

Generally, yes, throw.

Sometimes an optional is better, such as when downstream already takes one.

Occasionally, checking whether the operation (and a bunch of others) would succeed is best, particularly in high-rel/high-av systems. There, you are probably also logging, first, what you are about to attempt.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: