The Midrash poignantly describes the scene:
"The tribes were occupied with selling Joseph. Jacob was occupied with his sackcloth and fasting, and Judah was occupied with taking a wife.And God? He was busy creating the light of the Messiah."
The Matching Gift
The Maggid told the story of a wealthy man who married off his son. The local rabbi, ever the dignified scholar, sent a congratulatory letter—eloquent, poetic, written in exquisite calligraphy. It extolled the virtues of the bride and groom, praised the nobility of their families, and wished many blessings for the couple's future.
There was just one small hitch. The rabbi, in his haste, had forgotten to procure a decent piece of parchment for his grand letter. Instead, he wrote it on a scrappy, crumpled piece of paper—creased, frayed at the edges, probably salvaged from some forgotten desk drawer (or, let’s be honest, the wastebasket).
The wealthy man, upon receiving it, frowned. A gift so grand, wrapped so poorly? It rankled. But he held his tongue. It was his son’s wedding, after all. No need to spoil the joy.
Later, when the festivities were over, the wealthy man devised his revenge. He sent a gift to the rabbi—a basket laden with the finest fruits and richest cakes. The kind of spread that would make anyone salivate. But rather than a tasteful presentation, he placed it in a battered bowl, covered it with a soiled napkin, and enlisted a bedraggled street urchin to deliver it.
The rabbi, upon receiving the curious package, was mystified. He turned the bowl over, examined the napkin with scholarly precision, and gave a "humph" upon seeing the treasures inside.
A few days later, when the rabbi met the wealthy man, he asked, "Tell me, why would you send me such a splendid gift wrapped in such miserable rags?"
The wealthy man spread his hands. "Why not?" he said. "You sent me a beautiful gift in an ugly vessel. I simply returned the favor."
Repaying Judah
The Midrash teaches us that Joseph’s descent into Egypt was not an accident but part of the "profound counsel" of God’s covenant with Abraham—the Brit Bein HaBetarim. "They will enslave and persecute them," God promised, setting in motion the creation of the Jewish people.
God had many ways to bring Joseph to Egypt. The brothers, jealous of Joseph and eager to disprove his dreams, became unwitting instruments of God’s plan. The outcome—the descent of the family to Egypt and their preservation from famine—was ultimately for the best. But the means by which it happened were far from noble: betrayal, deceit, and lies to their father. A deeply human failure, to say the least.
And here’s where the Midrash imparts a powerful lesson. The affair of Tamar was not just an isolated, strange incident; it was an example of middah k’negged middah—measure for measure. Judah, who had used a goat to deceive his father about Joseph’s disappearance, now found himself deceived by Tamar with the same object—a goat. “Do you recognize this?” she asked him, mirroring the very words he had used with his father.
In the end, Judah’s punishment was not one of cruelty, but of poetic justice. God’s plan for the redemption of Israel and the coming of the Mashiach was set in motion—but it came in a form far from glorious. The promise was kept, but the vessel through which it was delivered was tarnished, reflecting the same traits that Judah had embodied in his dealings with his brother: deception, shame, and moral compromise.
(Adapted from Mishlei Yaakov, pp. 73-74)