Hacker News Re-Imagined

Including “And. And. And. And. And.” in a Google doc causes it to crash

  • 1473 points
  • 2 months ago

  • @patneedham
  • Created a post

Including “And. And. And. And. And.” in a Google doc causes it to crash


@Normal_gaussian 2 months

Replying to @patneedham 🎙

Perfect prank document to send to the team. I'm just hoping it holds up until the morning so everyone can join the fun and not just those of us with bad work time habits.

Reply


@analog31 2 months

Replying to @patneedham 🎙

An odd coincidence, I recall that pressing an operator button on an older HP calculator would also cause an error, because the stack was 4 levels deep.

Reply


@selimthegrim 2 months

Replying to @patneedham 🎙

Heaven brings forth innumerable things to nurture man. Man has nothing good with which to recompense Heaven.

Reply


@loxias 2 months

Replying to @patneedham 🎙

I LOVE stuff like this. Reminds me of "OpenOffice does not print on Tuesdays" https://beza1e1.tuxen.de/lore/print_on_tuesday.html

Reply


@jrd79 2 months

Replying to @patneedham 🎙

That is an amazing bug.

Reply


@likortera 2 months

Replying to @patneedham 🎙

Wonder if this was discovered because of a Mars Attack ET using it.

Reply


@ronald_raygun 2 months

Replying to @patneedham 🎙

I can't get the bug to reproduce. But maybe someone else could try

Wouldn't the sentence 'I want to put a hyphen between the words Fish and And and And and Chips in my Fish-And-Chips sign' have been clearer if quotation marks had been placed before Fish, and between Fish and and, and and and And, and And and and, and and and And, and And and and, and and and Chips, as well as after Chips?

Reply


@X6S1x6Okd1st 2 months

Replying to @patneedham 🎙

Replicated on my end on OSX & firefox

Reply


@sharmavinu0024 2 months

Replying to @patneedham 🎙

good tool for everyone.

Reply


@AlexMuir 2 months

Replying to @patneedham 🎙

Took me right back one of many detentions I served at school, when Mr B Swales set us the challenge of finding a grammatically correct English sentence with five ands in a row.

The answer was as follows:

The landlord of the "Dog and Partridge" pub commissioned a signwriter to letter a new board outside. On looking at the work, the landlord declared that he liked the colour but would prefer more spacing between Dog and and, and and and Partridge.

Reply


@mc4ndr3 2 months

Replying to @patneedham 🎙

Grammar check problems strike again.

Reply


@blueberrychpstx 2 months

Replying to @patneedham 🎙

When I come across posts like these, I just wonder, "How in the world did the user discover this in the first place?!"

Let's place bets:

A) The user just let autocomplete "take it away" (not sure about this one since they were able to access the console)

B) Pen Testing?

C) Error copy and pasting?

D) Actual dialog in a sci-fi post-apocalyptic love story where a robot discovers the Turing test and attempts to set itself into an infinite loop.

Reply


@JoeAltmaier 2 months

Replying to @patneedham 🎙

Who. Who. Who. Who. Who.

However. However. However. However. However.

Why. Why. Why. Why. Why.

Reply


@dr_dshiv 2 months

Replying to @patneedham 🎙

Whhhhhy

Reply


@rikeanimer 2 months

Replying to @patneedham 🎙

omg I tried to post a reply on that support page and it errored out saying "you need to be signed in ..." while I could literally see my sign in logo top right corner of the page.

fking google.

there are good [as well as technical humurous] comments on the page.

Reply


@valenaut 2 months

Replying to @patneedham 🎙

Reproduced in Safari on macOS Monterey.

"And. And. And. And." caused no problems.

"And. And. And. And. And. And." also crashes (5 "And."s is a substring, so makes sense).

I cannot imagine how this bug is occurring.

Reply


@twism 2 months

Replying to @patneedham 🎙

Repro'd

Reply


@dropit_sphere 2 months

Replying to @patneedham 🎙

lolwhat, replicated w/Linux and Chrome just now.

Reply


@edgyquant 2 months

Replying to @patneedham 🎙

This doesn’t work on the iOS app, I’ve pasted it and typed it manually

Reply


@strictfp 2 months

Replying to @patneedham 🎙

And?

Reply


@shreyansh26 2 months

Replying to @patneedham 🎙

Reproduced on Edge on Windows 11 as well. What a bug! Really need to know the root cause of this.

Reply


@endisneigh 2 months

Replying to @patneedham 🎙

I wonder if this is crashing due to some auto completion shenanigans

Reply


@mikotodomo 2 months

Replying to @patneedham 🎙

OMG I showed this to my friends and now someone in my class keeps adding it to our documents.

Reply


@zciwor 2 months

Replying to @patneedham 🎙

Will 100% be pasting this into a coworker's Google Doc with a white font color.

Reply


@LordDragonfang 2 months

Replying to @patneedham 🎙

If I had to guess, I suspect this is due to some very weird edge case with their recently implemented grammar checker.

Doesn't appear to be an issue for the android app, but that might be a cache thing.

Reply


@aliljet 2 months

Replying to @patneedham 🎙

And here's a link to a document where you can see the bug in action. https://docs.google.com/document/d/1KKZHZpKRFRBddEvjFc-au2LM...

Reply


@wardedVibe 2 months

Replying to @patneedham 🎙

didn't happen in firefox on Ubuntu

Reply


@yashg 2 months

Replying to @patneedham 🎙

Nothing is happening. Tried in both Firefox and Chrome.

Reply


@oblosys 2 months

Replying to @patneedham 🎙

Here's a bug I discovered in MS Word in 2004, which has survived the past 18 years of updates and is even present in the web version: https://1drv.ms/w/s!AgYiBqBjIZZpfkcvO9jnOel9T2o?e=tFA4wp If you join the two lines using a backspace at the start of the second line, the second line turns into gibberish.

Reply


@fedeb95 2 months

Replying to @patneedham 🎙



@mxuribe 2 months

Replying to @patneedham 🎙

Wow, this is pretty silly, odd! :-)

Reply


@seangrogg 2 months

Replying to @patneedham 🎙

“And.” I wrote. “And. And. And. And.”

That was the part that led to the apocalypse.

This was not a coincidence, because nothing is ever a coincidence.

Reply


@ricardobayes 2 months

Replying to @patneedham 🎙

I'm glad I was here when this historical event happened.

Reply


@ineedasername 2 months

Replying to @patneedham 🎙

Buffalo. Buffalo. Buffalo. Buffalo. Buffalo. doesn't crash it

Reply


@queuebert 2 months

Replying to @patneedham 🎙

I tried this on my typewriter, and nothing happened.

Reply


@Nitramp 2 months

Replying to @patneedham 🎙

I think the engine is just offended by your terrible writing style.

Reply


@blatherard 2 months

Replying to @patneedham 🎙

It's been fixed.

> May 6, 2022 Update: We have fixed an issue in Docs related to repetitive use of the word ‘and.’ This fix should soon be in place for all customers.

Reply


@bitwize 2 months

Replying to @patneedham 🎙

I wonder if "James where John had had had had had had had had had had had a better effect on his teacher" does someone's grammar checker up in knots. Or any of the old standbys, like "Police police police police police police".

Reply


@petters 2 months

Replying to @patneedham 🎙

I had an exam in image analysis once. There was a photo of a text "Sea and land".

The task was to "determine the cross ratio between sea and and and and and land".

Reply


@skerit 2 months

Replying to @patneedham 🎙

That was fun!

Reply


@mark_prutskyi 2 months

Replying to @patneedham 🎙



@daniel_iversen 2 months

Replying to @patneedham 🎙

Reminds me of this episode from IT Crowd :-) https://www.youtube.com/watch?v=OqxLmLUT-qc

Reply


@kodeninja 2 months

Replying to @patneedham 🎙

Big Andian bug.

Reply


@bspear 2 months

Replying to @patneedham 🎙

How random. Can't wait to try this

Reply


@piemadd 2 months

Replying to @patneedham 🎙

sounds like a markov chain going berserk

Reply


@thekiptxt 2 months

Replying to @patneedham 🎙

> Google Docs uses a "Markov Chain" to predict the next word for autocompletion purposes. In this case, of course, since we've already written "And" 5 times, the only logical next word would be "And", as showed in Djikstra's 1989 paper on the subject. Therefore, the Markov Chain never terminates and hence the memory chain overflows with infinite ands.

Does anyone know why this bug doesn’t repro for some words other than And if this is the case?

Reply


@sillysaurusx 2 months

Replying to @patneedham 🎙

Sort of related, last night I managed to make Clang crash by feeding it a certain C++ program: https://i.imgur.com/r5MC2aK.png

It was very surprising that there was a way to get Clang to segfault. Should I report it somewhere?

The code is basically doing a recursive template expansion with some C++20 concept constraints. So it's not quite as simple as "And. And...", but it's similar in that certain input text causes a crash. I just have no idea whether to report it, or where.

Reply


@mintplant 2 months

Replying to @patneedham 🎙

Relatedly, I have a string of text that, when pasted into Windows 11's Notepad, consistently causes it to crash. I don't know who to report this to.

Reply


@whoevercares 2 months

Replying to @patneedham 🎙

someone cut a sev2

Reply


@magneticnorth 2 months

Replying to @patneedham 🎙

Reproduced on Brave browser on Mac OSX.

Hypothesis from chatting about this with people nearby - somehow this string makes the grammar engine search space too large (that's the AI that predicts your next words) and it's running out of memory.

Reply


@captaincaveman 2 months

Replying to @patneedham 🎙

has anyone tried "Or. Or. Or. Or. Or."?

Reply


@raffraffraff 2 months

Replying to @patneedham 🎙

Only tangentially related, and not at all serious, but this reminded me of the Irish film "The Committments" (1991) in which a working class Dublin guy puts together a soul band. He's introduced to two promising musicians who are already in a band...

Jimmy: What do you call yourselves?

Derek: "And And And."

Jimmy: "And And fuckin' And?"

Derek : Well, Ray's thinking of putting an exclamation mark after the second "and." Says it'd look deadly on the posters.

Jimm: Psshh...

Outspan: You don't like it? You think it should go at the end?

Jimmy: I think it should go up his arse.

Outspan: Well, we're not married to it.

Reply


@AccountAccount1 2 months

Replying to @patneedham 🎙

I find it very poetic that this crash was triggered by a poem, here's the poem:

> Duration and the body: I thought about something I had read a while ago which said that a body, the body, is defined by duration. That a body in the present is inseparable from its previous state, that a body is linked in a continuous strand… and so on and so on… I thought about my body. It’s past. It’s present… Which made me think about the word and. And. And. And. And. And. Then.

> Now. Now. Now. Now. Now, I felt in the present like I was living always alongside a previous body. This is why I had expected to find myself in the apartment when I returned home from California.

https://durationandthebodyelizacallahan.cargo.site/

Reply


@eek2121 2 months

Replying to @patneedham 🎙

Guess they already fixed it.

Reply


@nofunsir 2 months

Replying to @patneedham 🎙

James while John had had had had had had had had had had had a better effect on the teacher. (1)

Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo. (2)

[1] https://en.wikipedia.org/wiki/James_while_John_had_had_had_h...

[2] https://en.wikipedia.org/wiki/Buffalo_buffalo_Buffalo_buffal...

Reply


@graderjs 2 months

Replying to @patneedham 🎙

What if you put it in a spreadsheet cell, calendar description, drawing text or email?

Reply


@iagocds 2 months

Replying to @patneedham 🎙

The Android App does not crash, but if i try to open the file at the web version it crashes

Reply


@calebegg 2 months

Replying to @patneedham 🎙

Something I recently found out about is you can go to https://docs.new to create a new Google doc.

Reply


@jonnycomputer 2 months

Replying to @patneedham 🎙

Favorite comment on that page: "Google is a small indie company btw"

So, more seriously, what might cause this (mis)behavior?

Reply


@Sohcahtoa82 2 months

Replying to @patneedham 🎙

Typing "And. And. And. And. And." did not reproduce the bug, but copy/paste the "And [...]" from the title of this post did.

EDIT: Ah, I had to reload the page, thank you child comments.

Reply


@draxil 2 months

Replying to @patneedham 🎙

Sounds like a feature, not a bug.

Reply


@fareesh 2 months

Replying to @patneedham 🎙

Did this bug emerge after their Orwell word policing update?

Reply


@truly 2 months

Replying to @patneedham 🎙

It seems to be fixed now. It would be fascinating to read an analysis of what exactly leads to the bug.

Reply


@westonjackson 2 months

Replying to @patneedham 🎙

Disable spelling and grammar checks in a separate doc and return to the broken doc is a possible workaround

Reply


@okaydeveloper 2 months

Replying to @patneedham 🎙

The engineer at Google will be sweating now. The secret is out.

Reply


@metalliqaz 2 months

Replying to @patneedham 🎙

The following also triggers the bug:

Also. Also. Also. Also. Also.

Reply


@pipeline_peak 2 months

Replying to @patneedham 🎙

I couldn't reproduce the bug. Just five and's with periods and spaces in the body of a document?

Reply


@tnli 2 months

Replying to @patneedham 🎙

Little Andy we call him.

Reply


@dreamcompiler 2 months

Replying to @patneedham 🎙

Reminds me of this old Star Trek chestnut:

https://www.youtube.com/watch?v=4WRtqmHpLvg

Reply


@croddin 2 months

Replying to @patneedham 🎙

"Also. Also. Also. Also. Also.\n" also breaks it.

Reply


@sam1r 2 months

Replying to @patneedham 🎙

I’m willing to bet it’s related to this. Google docs is trying to guess something for autocomplete, similar to their gmail feature to complete your sentences.

Which means, on a privacy standpoint, whatever you’re writing and guessing, they are absolutely processing something.

We the user are the product, apparently. This is mildly creepy to me because, I do vent on google docs sometimes. And assume only I can read it..

Reply


@ayashko 2 months

Replying to @patneedham 🎙

Reminds me of an old joke;

– I bet you a beer you can't make a logical, grammatical sentence with five ands in a row

– I used to be a sign writer in a previous life and one of the jobs I had was to repaint the sign hanging over the door to this very pub. Except the publican was adamant that he wanted more space between the words. Where exactly I asked? In between the Pig and and, and and and Whistle he replied.

Reply


@rossdavidh 2 months

Replying to @patneedham 🎙

Looks like HN is able to handle it just fine, though. :)

Reply


@croddin 2 months

Replying to @patneedham 🎙

"Anyway. Anyway. Anyway, Anyway. Anyway.\n" will break it too. Anyway...

Reply


@vesinisa 2 months

Replying to @patneedham 🎙

I remember discovering that pasting a specific emoji to Google Slides causes the slide to become "poison". You could not view or edit it, the web UI would crash if you clicked on the slide. I discovered this by accident, but did not think much of it as I was able to work around by deleting the slide from the document overview.

Reply


@herpderperator 2 months

Replying to @patneedham 🎙

Google has responded:

> Dear Google Docs users, we are aware of the issue and working on a fix right now. Thank for surfacing this issue and sharing it with us. We will keep you posted!

> Deving

> Google Employee

Reply


@throw7 2 months

Replying to @patneedham 🎙

I've had emails crash gmail on my phone still to this day. Typically it's stuff like output logs. My guess is something to do with the repetitive lines, but who knows.

Reply


@smcnally 2 months

Replying to @patneedham 🎙

“And And! And.” was Outspan Foster’s band before joining “The Commitments”[0] and later The Frames (as Glen Hansard). The screenplay was written before gDocs.

[0] https://www.imdb.com/title/tt0101605/quotes/qt0310982

Reply


@kklisura 2 months

Replying to @patneedham 🎙

``` TypeError: Cannot read properties of null (reading 'C') at Ccf (https://docs.google.com/static/document/client/js/157553674-...) at Bcf (https://docs.google.com/static/document/client/js/157553674-...) ```

Has something to do with grammar. The document does not fail when `Show grammar suggestion` is turned off.

Reply


@srinathkrishna 2 months

Replying to @patneedham 🎙

What's pretty annoying is that users are providing free QA for Google!

Reply


@tmalsburg2 2 months

Replying to @patneedham 🎙

Can't replicate this bug in current Firefox on Ubuntu 21.10. They've probably fixed it.

Reply


@goody71 2 months

Replying to @patneedham 🎙

Will Pat Needham get any Google Bux for finding this?

Reply


@bufferoverflow 2 months

Replying to @patneedham 🎙

I'm surprised Google didn't fuzz Google Docs.

Reply


@patneedham 2 months

Replying to @patneedham 🎙

Discovered by Eliza Callahan triggered by a poem in the middle of her novel. (Friend of a coworker) That poem can be found here: https://durationandthebodyelizacallahan.cargo.site/ - if viewing on mobile you have to Request Desktop Site for some reason, at least on Android it initially shows up as a Lorem Ipsum page

Reply


@munk-a 2 months

Replying to @patneedham 🎙

And thus has Eliza Callahan suddenly found themselves a poet with a lot more name recognition among tech workers.

Reply


@iamyatin 2 months

Replying to @patneedham 🎙

6th May, with the "And. And. .." crash found on Google Docs Skynet rose to the surface.

Reply


@Ansil849 2 months

Replying to @patneedham 🎙

This reminds me of when Google claimed that the number one was copyrighted [1]

[1] https://www.pcmag.com/news/google-drive-flags-text-files-con...

I don't recall that the reason for that bug was ever explained. I wonder if the reason for this one will be.

Reply


@kabes 2 months

Replying to @patneedham 🎙

Is this fixed? Can't seem to reproduce this (chrome on ubuntu)

Reply


@Patrol8394 2 months

Replying to @patneedham 🎙

Once a customer was able to destroy an old ES cluster because they copy pasted some text from a PDF into a search box ... that text got sent directly to the ES cluster without much escaping ... there were lots of "*" in there.

The query complexity exploded, ES ran out of memory, and the index got corrupted and I don't remember why, it could not recover.

We had to re-index all the data. Lots of fun.

Lesson learned: prepare for the impossible, keep your infrastructure up to date, escape queries :)

Reply


@fortran77 2 months

Replying to @patneedham 🎙

It crashes for me in Chrome on windows 11, but not Edge.

Reply


About Us

site design / logo © 2022 Box Piper