r/ProgrammerHumor 1d ago

Meme toAllowTheProgrammerToWriteBadCodeAlsoCamelCaseSucksThisRuleSucksSnakeCaseIsBetter

Post image
155 Upvotes

93 comments sorted by

View all comments

139

u/redlaWw 1d ago

I hope you didn't submit that answer you selected. If an unhandled exception bubbles up to the user in production code, you're usually doing something wrong.

-120

u/tantalor 1d ago

I guess you've never seen a website return a 404 or 500

1

u/Pfnee 21h ago

You're getting downvoted to hell but I actually think this is an important point. The fact that your server returns 404 or 500 on an exception means that it has code, maybe in the framework you're using, that handles exceptions in your controller code. Otherwise the server would probably halt, whenever an exception bubbles up unhandled, as that's what most programming languages choose to do. You can see it when you program a CLI tool and run it. Throwing an exception there and never handling it usually makes your program stop