Wash me thoroughly from my iniquity, and cleanse me from my sin. For I know my transgressions, and my sin is ever before me.” - Psalm 51:2-3
With repentance and confession, God forgives instantly. But He doesn’t remove the consequences of our sin. We have to live with those consequences.
Those consequences are our earthly punishments.