I'm so sorry this man did not live up to the best self you saw in him. That's a tragedy.
But you have prevented another tragedy by seeing him clearly and getting him out of your life. You could have chosen to stay with him. And things would have gotten worse, maybe much, much worse.
It's certainly good to mourn the loss of the person he might have been, and your relationship with that might have been person.
But give yourself some props - especially now - for getting yourself out. I see too many people who stay, wishing and hoping for the might have been person to reappear. You are brave and you value yourself. That deserves praise.