Ephesians 6:4
ESV - 4 Fathers, do not provoke your children to anger, but bring them up in the discipline and instruction of the Lord.
For follow-up discussion and general commentary on the topic. Comments are sorted chronologically.
To answer your quetion, let’s examine what is sin.The Greek word for Sin actually means to miss the mark, or target. It is like an archer missing the target with an arrow. So what is the target we as humans should shoot for, in regards to what God wants? God's Word says we should be righteous or do what is right. So if abandoning a child is not right, then it is a sin.