I don’t know who remembers the first season of Criminal Minds but the lead investigator was played by Mandy Patinkin, a wonderful (and very professional) actor with a longstanding reputation for excellence. But he refused to do more than that first year and resigned. He stated (and I’m paraphrasing) that he just found the requirements of continually dealing with the details of some of the most gruesome psychopathic acts imaginable to be just too much to handle both emotionally and spiritually. (I believe he is an Orthodox Jew.)
He received criticism in some corners for this but I and many others respect him for being true to his sense of conscience.
Even in real life, if a law enforcement person finds that they cannot handle some of the gruesomness that the job
entails, nobody blames them for resigning to find another profession. How much more so for an actor.
For Patinkin, this was just not a role that he felt suited to play. And there are numerous cases where actors will refuse roles for which they don’t feel equipped to handle, either emotionally or otherwise
If an actor is uncomfortable playing gay then I think it would be more unprofessional of him to commit to this role simply out of political correctness or fear of being thought of as homophobic.
That is just being fake and pretentious as well as unprofessional.