As is the case with many, if not most, of the proverbs, it is only generally true. The proverbs are "rules of thumb" not inviolate laws of nature.
Another obvious example....
Proverbs 22:6 Train up a child in the way he should go, And when he is old he will not depart from it.