Why would a guy date someone he doesn’t find attractive?

I dated this guy for three years. We barely went out on dates but whenever we did go out We only went to the movie theater. A few times when we went to the movies and it was crowded He would complain and act uncomfortable or say he wanted to go home And one time when we were at the movies the movie ended, he sat in the chair and told me to just go ahead to the exit When this happen, I confronted him and asked him if he didn’t want to be seen with me in public. He told me it was not like that and he just has anxiety. Whenever we went to the grocery store he would look uncomfortable or walk behind me, and he only showed me affection when the aisle were empty. And there are a lot of other examples I have But He would always tell me he just has social anxiety and just didn’t want to be around people. Last month we got into a really bad argument and he called me ugly said I was sloppy and said I look like an ape The next day he told me, he only said those things because he was mad. And today I asked him when he would take me out on a date he told me he would take me out tonight, when I told him I wanted to go to a restaurant instead of the movies he told me not to embarrass him and claim he was joking. When he said that I finally realized he was not attracted to me and did not want to be seen with me in public so I ended things with him why would he date me for three years if he was embarrassed to be seen with me in public and didn’t really find me attractive
Why would a guy date someone he doesn’t find attractive?
Post Opinion