A person who currently possess the Spirit also possess sanctifying grace whereby they are made just and holy. Anyone who dies with sanctifying grace has the Spirit, therefore, they will not be condemned by the eternal punishment due to sin.
Yes, a person must lose the Spirit in order for them to be condemned. They who commit mortal sin and die impenitent prove themselves to not be the children of God anymore, but the children of the devil in as much as they do unrighteousness and don’t possess inward charity. “In this the children of God are manifest, and the children of the devil. Whosoever is not just, is not of God, nor he that loveth not his brother.” (1 John 3:10). Only they who by faith, have been united to Christ and, being perfected by charity, grow more and more in their justice, they are the children of God. “For whosoever are led by the Spirit of God, they are the sons of God.” (Romans 8:14). How then do we know that one is lead by the blessed Spirit and possess that sanctifying grace needed to inherit eternal life? The previous verse explains it well, “For if you live according to the flesh, you shall die: but if by the Spirit you mortify the deeds of the flesh, you shall live.” (Romans 8:13). Those then, who mortify the desires of the flesh (sin) and crucify their lusts, they are properly called the sons of God. Those that are in Christ have the Spirit (Romans 8:9) and as the Apostle asserts, “And they that are Christ's, have crucified their flesh, with the vices and concupiscences.” (Galatians 5:24).
As regards our peace of conscience and sense of God’s love towards us I will only say that we must trust only in the mercy and grace of God. If any person begins to place themselves as the primary source of comfort they will live the rest of their lives in torment. No, we must indulge ourselves in the grace and goodness of our God who’s bowels of compassion enticed Him to send His Son to merit salvation for His people. Everyday, when you examine your conscience remember to pray to God, “Oh Lord! You know I am a mere worm. A sinful and prodigal soul. I pray you, most merciful God, that you would have mercy on me. If You should mark my sins, who could stand? For all your servants and sons have many blemishes and many defects. But with you there is forgiveness. Oh God, do not judge me according to Your justice, but according to Your mercy. In You alone do I place my trust and in You alone do I hope to be saved. Amen.” And may we, like St. Ambrose, trust only in the mercy of God in that dreadful day when the souls of men will be before the Judgment Throne of God. “Let no man arrogate anything to himself. Let no man glory in his own merits or good deeds. Let no man boast of his power. Let us all hope to find mercy by our Lord Jesus, for we shall all stand before his judgment seat. Of him I will beg pardon. Of him I will desire indulgence. What other hope is there for sinners?”