Hi, I'd like to help you with your question.
It sounds like this person set off something inside of you that triggered an unmet need or longing. You mentioned the red flags that you kept seeing when you were with him. This could have been either the caution you felt about getting close to him because of the intensity of the feelings (past issues you have unresolved), or there was things about him that made you move away from the relationship.
How was this person with you? Did they feel the same way about you that you did with them? Were the red flags you mentioned a deterrent to having a good, solid relationship? These are important questions you need to ask yourself. It will tell you more about whether or not this could have been a fulfilling relationship.
Given what you said in your question, my feeling would be that there is an unresolved issue you need to deal with and that caused the feelings you have for him. Think about whatever it was about this person that you feel so attracted to. It's going to most likely be emotionally based so it may be hard to pinpoint. But what you feel comes up for you is most likely related to what your need is.
Any unresolved issue is going to come from the past. Did you have a difficult or traumatizing childhood? Was there a pivotal relationship in your life that held strong meaning for you? Was there an event or incident that occurred in your life that affected you a great deal? Do you feel there are any needs you haven't address in your life?
This is a pretty deep issue that you may want to talk to a therapist about. I noticed that you said you have tried therapy. You may want to bring this up again with the therapist you had (if they were helpful) or try another therapist.
If there is more you'd like to add or any other way I can help, please let me know.
I hope this helped you,