Live data from Hacker News

418 I’m a teapot

developer.mozilla.org

131–140 of 146 posts

Re: 418 I’m a teapot

#131

Earlier quoted context omitted.

You're doing the thing he was trying to avoid. You want to have a discussion about this hypothetical emoji and make a bunch of statements about the psychology of the person who doesn't want to waste his life on it. Nothing like being accused of not liking "fun" when you don't want to do something useless at work. Maybe not everybody likes goofy emojis, or Harry Potter references, or whatever easy nothing passes as wi…

As a former engineering manager: no, I don't want to have a discussion about the hypothetical emoji. I want the engineer to put a rocketship in their commit message to have a slightly brighter day, and I want to acknowledge that someone else made a positive comment about it. If you are genuinely at the point in your life where "people saying they like things" is the same as ... what you're describing ... please be aw…

Because nothing brightens an engineer's day like putting rocketship emojis in commit messages

Re: 418 I’m a teapot

#132
This always reminds me of a great find I discovered a while back when I was reading the HTTP/2 RFC for whatever reason.

Back before "429 Too Many Requests" was standardized, Twitter's API used to return a nonstandard 420 status code (with the caption "Enhance Your Calm") when rate-limiting incoming requests. They stopped doing this for understandable reasons, but the caption, at least, got snuck into HTTP/2, see:

https://datatracker.ietf.org/doc/html/rfc7540#section-7

down at 0xb, the caption for disconnection due to excessive load is, indeed, ENHANCE_YOUR_CALM. Always makes me smile. :)

Re: 418 I’m a teapot

#133

Earlier quoted context omitted.

Quick side-note. Thank you for freesolitaire.win. It's such a beautiful implementation of solitaire. Works so well as a PWA, I can enjoy it even without proper internet connection, it's simple, does the basics, but does it perfectly. There's nothing to add to it, but more importantly... nothing to take out. I wish more software was written like this. I've donated already, but I use it so much I'll donate again.

Wow, thanks jbombadil! That’s so heart-warming to hear https://FreeSolitaire.win that much! Thank you again for your kind words (and donation!)

Also a +1 for the solitaire! One suggestion: how about an inverted mode where the piles grow up from the bottom? I think it would be much easier to control while playing on phone

Re: 418 I’m a teapot

#134

Earlier quoted context omitted.

Wow, thanks jbombadil! That’s so heart-warming to hear https://FreeSolitaire.win that much! Thank you again for your kind words (and donation!)

Also a +1 for the solitaire! One suggestion: how about an inverted mode where the piles grow up from the bottom? I think it would be much easier to control while playing on phone

Oh that’s an interesting idea! Thanks Dave, had not think about that!

Regarding playing on phone: one improvement I have in mind, is to have the stock (aka reserve) and waste piles be on the right side. That would make them easier to reach for right-handed players, I guess. What do you think? (The foundations piles would inversely go to the left. They are rarely manipulated, given that one can double-tap a card to automatically send it to its foundation pile.)

Thank you again for the feedback, that’s always very appreciated!

Re: 418 I’m a teapot

#135

Earlier quoted context omitted.

Also a +1 for the solitaire! One suggestion: how about an inverted mode where the piles grow up from the bottom? I think it would be much easier to control while playing on phone

Oh that’s an interesting idea! Thanks Dave, had not think about that! Regarding playing on phone: one improvement I have in mind, is to have the stock (aka reserve) and waste piles be on the right side. That would make them easier to reach for right-handed players, I guess. What do you think? (The foundations piles would inversely go to the left. They are rarely manipulated, given that one can double-tap a card to au…

I think that in such a UI where it's trivial to mirror left and right just give an option and let the user decide their preference

Re: 418 I’m a teapot

#136

I use 418 as a reply to illegitimate bots. It’s fun and it makes filtering logs easier. Nginx config snippet: # Nothing to hack around here, I’m just a teapot: location ~* \.(?:php|aspx?|jsp|dll|sql|bak)$ { return 418; } error_page 418 /418.html; Example: https://FreeSolitaire.win/wp-login.php (NB: /wp-login.php is WordPress login URL, and it’s commonly blindly requested by bots searching for weak WordPress installs.…

444 might be quicker, if less fun. https://nginx.org/en/docs/http/ngx_http_rewrite_module.html#... Wonder how to ban that address permanently just for asking for these urls?

> Wonder how to ban that address permanently just for asking for these urls?

fail2ban supports rules based on nginx logs (clients that triggers x 444 responses in y minutes (or y-times) gets banned for n minutes/hours/days)

Re: 418 I’m a teapot

#137
post #51

If you are bored you can read the discussion when _mnot_ tried removing 418 status code from different languages and implementations because it wasn't technically correct. https://github.com/nodejs/node/issues/14644 https://github.com/golang/go/issues/21326 And someone even ended up making a website http://save418.com/

This 418 stuff reminds me of a previous job where we had some arguments about putting emojis in our applications. I was against it and a coworker was for it. Like putting rocket ship emoji when an operation succeeds. My main argument was that if you put things like that in your applications then people start having opinions about it and they want to discuss it and add more to certain places or remove from other place…

Whenever I catch myself having a discussion about having fewer discussions, I try to stop and just let it go.

Re: 418 I’m a teapot

#138

Earlier quoted context omitted.

444 might be quicker, if less fun. https://nginx.org/en/docs/http/ngx_http_rewrite_module.html#... Wonder how to ban that address permanently just for asking for these urls?

444 is a (nginx-specific) idea too, indeed. Blocking at the edge (on the CDN) is another, and it would be even quicker ;-) (I use Cloudflare, a Cloudflare worker could be set to answer /wp-login.php or anything, without even reaching my own server.) Wrt. how to ban: an option would be something like fail2ban ( https://en.wikipedia.org/wiki/Fail2ban )

> Blocking at the edge (on the CDN) is another, and it would be even quicker ;-) (I use Cloudflare, a Cloudflare worker could be set to answer /wp-login.php or anything, without even reaching my own server.)

With HTTPS, blocking on the edge requires using a CDN that holds your secret keys. The only way they could block paths is being able to decrypt requests since the path is encrypted. If you trust Cloudflare or someone else to manage your secrets, this will work, but if you are terminating your HTTPS connections, you'll need to handle it with your own infrastructure as people above have.

Re: 418 I’m a teapot

#139
post #105

Earlier quoted context omitted.

Could, but when it comes to handling errors in the frontend, I find it is easier for the discriminator to be the actual status code when possible, rather than needing multiple additional properties.

Surely "when possible" should be "when semantically correct"? I don't hate fun (see the threads on removing 418 from Node and Go for that), but misusing a joke status code in production to mean something completely unrelated seems less like fun and more like poor design.

There is no status code for captcha failures, so I don't think using 418 for that is "misuse".

By design, our API routes which utilize a challenge should not be consumed by others either, so even if using 418 somehow broke someone's attempted usage, that sounds like a feature not a bug.

Re: 418 I’m a teapot

#140

Earlier quoted context omitted.

You're doing the thing he was trying to avoid. You want to have a discussion about this hypothetical emoji and make a bunch of statements about the psychology of the person who doesn't want to waste his life on it. Nothing like being accused of not liking "fun" when you don't want to do something useless at work. Maybe not everybody likes goofy emojis, or Harry Potter references, or whatever easy nothing passes as wi…

As a former engineering manager: no, I don't want to have a discussion about the hypothetical emoji. I want the engineer to put a rocketship in their commit message to have a slightly brighter day, and I want to acknowledge that someone else made a positive comment about it. If you are genuinely at the point in your life where "people saying they like things" is the same as ... what you're describing ... please be aw…

it wasn't about putting emojis in commit messages, it was about putting them in the application
Post reply on HN