by CornCobs · 4y ago · 0 comments
Example 1: Chrome's dino page is actually great! Grandma doesn't fear it or call me out of panic the moment she sees it. Imagine if she got something like the default Apache 500 error webpage.
Example 2: the new BSOD. I saw on some other thread that some people hate it, but I think it's clear and directs the inexperienced user to what they could at least try to do
Here I was thinking that the very same group of people that think sl is a funny command line program wouldn't appreciate humanized error messages...
Yeah, I don't have any problem with "cute" error messages as long as they also contain all the info someone would need to identify the problem and if possible solve it. it's not the "cute" that's the problem really, it's the frustration and the lack of direction that usually comes with them.
I've seen HN commenters express extreme outrage over this ("They obviously know what you want to do, so why not just do it?!?!?"), but I love it. The first time I got that message, I considered it incredibly helpful, because sending EOF will work on any tool that reads from standard input, not just python. I hadn't known how to do that before the python shell taught me!
And from the implementation perspective, the python shell is trying to run a simple loop:
1. Read a line of python code.
2. Evaluate the code.
3. Print the result.
Defining `exit` as the name of a string slots into that loop seamlessly. Defining it as a special keyword that is recognized by the shell, despite the fact that it has no special meaning to python, means you're no longer just reading python code; now you have to implement a separate parser solely for the purpose of handling this command.