Well if God is punishing you, you should know why, because God does not punish His child and the child do not not know why. God punish His child for their good like a parent. If not , you are being tested. So you can grow in trusting God, which is growing in faith. So read your Bible , do not look for scripture formulas or quick fix prescriptions in the Bible. Pickup and read books of the bible.
If sin is in your life “Repent”
And ask for forgiveness:
5and ye have forgotten the exhortation which reasoneth with you as with sons, My son, regard not lightly the chastening of the Lord, Nor faint when thou art reproved of him;
6For whom the Lord loveth he chasteneth, And scourgeth every son whom he receiveth.
7It is for chastening that ye endure; God dealeth with you as with sons; for what son is there whom his father chasteneth not?
8But if ye are without chastening, whereof all have been made partakers, then are ye bastards, and not sons.
9Furthermore, we had the fathers of our flesh to chasten us, and we gave them reverence: shall we not much rather be in subjection unto the Father of spirits, and live?
10For they indeed for a few days chastened us as seemed good to them; but he for our profit, that we may be partakers of his holiness.
11All chastening seemeth for the present to be not joyous but grievous; yet afterward it yieldeth peaceable fruit unto them that have been exercised thereby, even the fruit of righteousness