Whilst your OP was a while ago now, you're still considering the situation so I thought I'd give my POV.
Your P tried to cheat on you.
He tried to have sex with someone else.
The only reason he didn't was because he was too stupid to realise he was flirting with a computer 🤦🏻♀️
He didn't confess to you, he lied about his efforts to cheat for five years.
You were having a relationship with a man who was desperately trying to get his end away elsewhere, but didn't because no one said yes (as they weren't real 🙄)
But actually, he may have stopped contacting the online chatters because he finally realised they weren't real and he went elsewhere and did have sex with another or multiple other people.
Have you had an STD check or a smear test recently to see if he's passed on HPV?
It looks like his sexual chats were a type of addiction and addicts rarely just stop, I would be worried that he'd found his "fix" elsewhere.