The earliest match for this popular quotation appeared in an essay by Theodor Reik in 1965. Currently, he is the leading candidate for coiner of the saying.
Ah, interesting. I just did a cursory Google search for the author of the quote and it said Mark Twain. Guess someone should file a bug for their knowledge graph team.
A cursory search might even give one the impression that Einstein had an opinion about bees. (Unkillable memes are pretty interesting.)
Meh. A lot of people have said that, some before disaster and some before victory. It was already an old saying when Pliny the Elder said it. Wellington made it his motto, and he beat Napoleon.
At the risk of explaining a joke, the idea was not that it’s something that’s only ever been said before failure, but that it’s a quite funny thing to say just before one.
At the risk of explaining my objection; it's not about the joke but about the premise of history rhyming generally being an artifact of overzealous pattern matching and the implicit exclusion of cases that don't match the target pattern.
Your objection to the joke has been duly noted in the appropriate system of record. Beep boop.