God looked down at the world before the flood and saw something He hadn't seen since the days of Adam — a civilization that had talked itself into impunity. The wicked had done the math. God swore He would never bring another flood. The oath was in the record. So they concluded: whatever we do now, the waters cannot touch us. (Genesis 6:5)
The book of Ecclesiastes knew this trap was coming. "There is a time for every experience, including doom — and a man's calamity overwhelms him" (Ecclesiastes 8:6). The point isn't that doom is inevitable. The point is that men who think they've found the loophole always miss it. The wicked of the flood generation understood the letter of the oath but not its spirit. God swore not to destroy the world again with water. He said nothing about fire. He said nothing about sword. He said nothing about war and famine and the weight of their own wickedness crushing them from within.
This is what Aggadat Bereshit, a 10th-century midrash on Genesis, opens with — not the story of Noah's righteousness, but the failure of those who thought they had figured God out. The lesson the rabbis wanted to land first: cleverness is not wisdom. Loopholes are not exits. The generation of the flood did not perish because they broke an oath — they perished because they used God's mercy as license for cruelty, and mercy, the rabbis said, is never a license for anything.