A woman from the tribe of Juhaynah came to the Prophet of Allah ﷺ while pregnant from adultery and said, "Prophet of Allah, I have committed an offense deserving the prescribed punishment, so carry it out on me."The Prophet ﷺ summoned her guardian and said, "Treat her well, and when she gives birth, bring her to me." The man did so.Then the Prophet of Allah ﷺ gave the order, and her clothes were tied securely around her. He commanded that she be stoned, and it was carried out. Afterwards, he prayed the funeral prayer over her.Umar said to him, "Are you praying over her, Prophet of Allah, when she has committed adultery?"He replied, "She has made such a sincere repentance that if it were divided among seventy of the people of Madinah, it would be enough for them all. Have you found any repentance better than her giving up her own life for the sake of Allah the Exalted?"
أن امرأة من جهينة أتت نبي الله ﷺ وهي حبلى من الزنا، فقالت: يا نبي الله! أصبت حدا فأقمه علي، فدعا النبي ﷺ وليها فقال: أحسن إليها، فإذا وضعت فائتني بها ففعل. فأمر بها نبي الله ﷺ فشكت عليها ثيابها، ثم أمر بها فرجمت، ثم صلى عليها، فقال له عمر: تصلي عليها يا نبي الله! وقد زنت فقال: لقد تابت توبة لو قسمت بين سبعين من أهل المدينة لوسعتهم، وهل وجدت توبة أفضل من أن جادت بنفسها الله تعالى.
Muslim narrated it in the Book of Hudud (1696) from Abu Ghassan Malik bin Abdul-Wahid Al-Masmai, who said, Muaz (meaning Ibn Hisham) narrated to us, my father narrated to me, from Yahya bin Abu Kathir, Abu Qilaba narrated to me, that Abu Muhallab narrated to him, from Imran bin Husayn, and he related it.