The 38th chapter of Genesis tells the story of Judah and Tamar. It’s a rather sordid tale. But the Bible is known for being open and honest when telling the story of humanity. It records the bad character traits as well as the good character traits of its heroes.