“Forgive and forget” is a human expression, but it doesn’t apply to God.
God, being an eternal, immutable Being, does not forget. For that matter, neither does he remember. Rather, all things, all events, all moments, and all places are always present to him.
The expressions used that “God forgets our sins” or “God no longer remembers our sins” are imperfect human expressions because we have no means of actually expressing the infiniteness of God using inherently finite human language, stuck in time and space as we are. When we loosely say God forgets our sins, it’s that he will not adjudge us guilty or culpable. He instead wipes away the guilt of that sin and makes us new creations.
When we, God willing, stand before the Final Judgment having died in the state of grace, all our deeds will be replayed for us, and that includes our sins. But for the elect, there will be no shame, no humiliation. Our sins will be revealed, but as will be the forgiveness of them. The saved will therefore glorify God for the mercy and grace he has given them, despite those sins.