The court case for the gay boyfriend fight that we thought would end in a murder conviction in Austin that happened in 2015 was underway this week and it ended with a surprise twist. The judge threw out the murder charge because the medical examiner basically messed up the autopsy. The alleged murderer was only charged with aggravated assault to the pet they shared.

A man who is suspected of beating his boyfriend to death no longer faces several felony charges, including a murder charge, after a Travis County judge tossed out the bulk of a medical examiner’s controversial testimony on Monday.

State district Judge David Wahlberg reversed his ruling from last week, announcing statements given from the witness stand by Dr. Sam Andrews are unreliable and that the jury in Bryan Canchola’s murder trial could not consider the portion that indicated how the victim died.

Absent a credible cause of death ruling, Wahlberg then acquitted Canchola of murder, manslaughter and aggravated assault involving serious bodily injury. Canchola, 22, had faced up to life in prison. He still faces a second-degree felony charge of aggravated assault by causing bodily injury with a deadly weapon, which carries a maximum sentence of 20 years in prison.

Wahlberg’s decision comes after Andrews, of the county’s medical examiner’s office, revealed last week on the day before he was set to testify that he had reached a new conclusion in the cause of Stephen Sylvester’s death. Andrews notified prosecutors Wednesday evening that after reviewing autopsy photos earlier in the day, he found evidence that showed the presence of blood in Sylvester’s brain. Two years ago, Andrews had concluded that the bleeding occurred in the neck.

Rather than him wait for the jury to assess punishment, Bryan Canchola agreed to a sentence of six months in jail on his Class A misdemeanor assault conviction. The sentence will run concurrently to a six-month sentence Canchola agreed to as part of a guilty plea on a related animal cruelty charge.

Canchola already served 42 days in jail following his 2015 arrest and likely will serve about 50 more with credit for good behavior. State district Judge David Wahlberg ordered Canchola to return to court at 9 a.m. Thursday to begin serving his sentence.

Bryan Canchola was found not guilty of felony aggravated assault with a deadly weapon. This was all due to a clarification on testimony related to a broken bone in deceased victim Stephen Sylvester’s neck. The testimony, presented last week by medical examiner Dr. Sam Andrews, related to the broken hyoid bone Sylvester sustained when he died in July 2015. Andrews testified that the injury was “acute,” meaning it probably happened shortly before Sylvester died and not several hours earlier when he fought with Canchola in the Austin apartment they shared near University of Texas.

The case took a significant turn Monday when Wahlberg threw out the bulk of the testimony from Andrews, ruling it unreliable. Andrews had irritated the judge last week by changing his cause of death ruling on the day before he was set to testify. He ruled Sylvester died from bleeding in the base of the brain after initially saying an artery in Sylvester’s neck was ruptured by a punch that broke the hyoid bone.

The family is still expected to file a wrongful death suit.