Live data from Hacker News

418 I’m a teapot

developer.mozilla.org

121–130 of 146 posts

Re: 418 I’m a teapot

#121

Every time I have encountered this error code in the wild I have been extremely frustrated. Somebody tries to be cheeky, and rather than just return the proper status code (like a 429 or 503) they return this, which breaks a lot of HTTP status code parsing. Not cheeky or funny. Boring actually. I know I'm boring but I have a job to do.

A possibly apocryphal didactic story relevant because if an HTTP implementation misses 418, what else does it miss?:

The story goes that Van Halen had stipulated on their concert rider that they wanted M&M candy backstage, but with all the brown ones removed.

In his autobiography ‘Crazy From the Heat’ singer David Lee Roth explained this was not just a childish request, but in fact was a cunning test whereby he could tell instantly if the venue was safe or not.

He reasoned that if a concert venue did put brown M&Ms out, then they cannot have read the rider properly and that they then might also have made other more dangerous errors, such as in their electricity supply or stage weight capacity.

https://www.metaltalk.net/chris-dale-myth-busting-the-van-ha...

Re: 418 I’m a teapot

#122

Earlier quoted context omitted.

> All those small discussions were essentially pointless Were they pointless, or were they positive feedback about a thing you personally disliked?

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 aware of the emotional impact you're having on the people around you.

Re: 418 I’m a teapot

#124
post #49

Earlier quoted context omitted.

Now. I didn't know about the RFC. This is so good. I hope we can continue to advance this field with good humor, and good coffee.

There are quite some RFC with humor, most prominently probably RFC1149 and its extension RFC2549

For anyone who wants to explore further, Wikipedia has a list page for these RFCs: https://en.wikipedia.org/wiki/April_Fools%27_Day_Request_for...

There are a lot more of them than I had realized before finding that. Some years even had multiple.

Re: 418 I’m a teapot

#125
post #118
post #112

Earlier quoted context omitted.

Out of paranoia I just checked and yeah, GoogleBot actual (and not the dozens of fakes) requested each 410'd URL at least once a month, some URLs get multiple requests per month. All have been marked 410 since 2014 or earlier.

Google has FoMO...

The webmaster tools used to say Google will punish your rank if the crawler gets too many 404 or 410...

Re: 418 I’m a teapot

#126

Earlier quoted context omitted.

If your parser can't handle in-spec error codes, then that's a parser problem.

Regardless of the parser if you're using a 4XX status code when you should be using a 5XX status code then you're simply doing it wrong.

Why would being a teapot justify being a 5xx status? The server hasn’t failed, it’s a functioning teapot, definitely not broken.

I would assume if the teapot were to be broken, then a 518 teacup is empty error would be more appropriate.

But as long as there is a piping hot cup of tea, then it’s a 418 code.

/s

Re: 418 I’m a teapot

#127

I think since it is I am a teapot not you are a teapot It should be a 5xx code because clearly it's a server side issue.

Disagree, asking a teapot for a cup of coffee is an invalid user request. The server is working as expected, but is not being asked to work as expected.

Agree, it’s a functioning teapot. Definitely 418.

If the cup is empty, then a 518 teacup is empty error would be more appropriate but as long as there is piping hot tea - 418 for me.

/s

Re: 418 I’m a teapot

#128
post #82

Earlier quoted context omitted.

The problem was people (including management) wanting to talk about where and how to put emojis once we added a few. The less I have to talk to management the better. All those small discussions were essentially pointless and they happened often enough that I was getting annoyed by them. Like, sometimes we would be showing "in development" stuff to clients and then they would interrupt and mention something like "nic…

It sounds like people really liked the emojis

People like novelty and engage on things they feel they can contribute an opinion on.

Been on many a demo in the past where all sorts of "magical" and complicated stuff is happening that ends up with "ooh I've never seen a date picker like that" or "wouldn't it be a lot better if it was blue and not red".

Often it's because they accept the other stuff is working or don't even fully remember what the demo is about.

Re: 418 I’m a teapot

#129

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?

Re: 418 I’m a teapot

#130

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?

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)

Post reply on HN