@Ales97862536@Maximumatheist In both cases God is warning the Hebrews of the price to be paid for turning away from him and breaking their covenant. You can find harshness in the God of the Old Testament. No doubt. But that is not the entire story.
@Ales97862536@Maximumatheist Yes it is the description of what the Hebrews will suffer from the siege of their enemies because they have turned away from God and he cannot help them. Don't forget Deuteronomy 28:53.