Please see 44:30. Alshich says the soul of a righteous person would not be bound up with the soul of a wicked person. What about Avraham and Yishmael; Yitzchak and Eisav; David and Avshalom.
Very nice point.
This Alshich is enforcing a rule that I have seen in the sefer by R’ Issac Sher ZT”L called “Leket Sichos Mussar”, that the people in the torah were all very big in their spiritual level, because otherwise the torah wouldn’t bother with them, the same way the torah didn’t write about millions of other people that lived. The sins that the torah discusses are only sins on the level of the giants being discussed, but they were all big tzaddikim. The classic example of this is that Eisav’s head actually made it into the Ma’aras Hamachpela, no one else’s head made it in!
This doesn’t mean that we shouldn’t learn a lesson from the simple meaning of the text, we should, but in truth their “sins” were very slight and they were all tremendous people.
If you will see the sefer, he goes through numerous stories in the torah and explains them in a fascinating and enlightening way