Being barred from running in party primary is extremely rare and I’m not sure how many states allow parties to do that. I believe in happened to a black democrat incumbent State Rep who moved right in....TN? GA?
Former State Rep. John DeBerry here in TN. He was stripped of his ability to run as a Dem because he was sane in his voting habits. Tried running as an Independent, but the district was too accustomed to voting for whatever had a “D” after their name.