In People v. Partee (Cal. Ct. App. 2018), defendant was convicted not just of misdemeanor contempt but also of being accessory after the fact to murder for refusing to testify against family members in a gang killing case; defendant said that

She feared retaliation by the gang (she had experienced retaliation in the past); she feared for her safety and that of her daughter; she did not want to alienate her family; all four of the accused were family to her, and she did not want them to go to prison for the rest of their lives because of her testimony. Defendant further acknowledged that when she refused to testify in 2015 she knew her failure to appear as a witness in 2008 had led to the murder case being dismissed. But she denied she was helping her brother avoid trial. She testified: "Well, you guys are saying that I am helping my brother avoid trial. I believe you guys still have a case without me." She added that when her family members discovered she had spoken with Detective Skaggs, they told her not to testify because "[f]amily is first."

California law defines an accessory after the fact as

Every person who, after a felony has been committed, harbors, conceals or aids a principal in such felony, with the intent that said principal may avoid or escape from arrest, trial, conviction or punishment, having knowledge that said principal has committed such felony or has been charged with such felony or convicted thereof ….

The offense could be punished as either a misdemeanor or a felony; here, defendant was sentenced to 365 days in jail and three years of probation for refusing to testify against family members. Defendant argued that her refusal to testify could only be punished as criminal contempt, and not on accessory-to-murder theory (which might in theory carry a much heavier penalty). The majority disagreed:

[D]espite being held in custody as a material witness and offered immunity and relocation, defendant's refusal to testify was motivated in part by the desire to ensure that her brother, cousin, and lifelong friends were not convicted and incarcerated. As a result, four accused murderers avoided trial and possible conviction. The prosecution, having tried in vain to compel defendant's testimony [including through a grant of immunity and offer of relocation], and no doubt desiring to discourage similar behavior by other witnesses, particularly in gang-related cases, resorted to the present prosecution. We find no legal authority precluding it…. Defendant claims she cannot be guilty as an accessory after the fact because her silence — refusing to testify — is not an affirmative act…. [But though t]he failure to act is not an `overt or affirmative' act unless there is a duty to act[,] … [a] witness who has been subpoenaed and given immunity that is co-extensive with the scope of her Fifth Amendment privilege has a duty to testify." Under these circumstances, defendant's "silence" was an overt or affirmative act falling within the terms of section 32 because she had a duty to testify at defendants' preliminary hearing.

Judge Lamar Baker, dissenting in relevant part, disagreed:

For 82 years, Penal Code section 32 has proscribed "harbor[ing], conceal[ing] or aid[ing] a principal" in his or her commission of a prior felony. Today, the majority affirms convictions under this statute that are, so far as the Attorney General is aware, literally unprecedented in its 82-year history. No California case has ever sanctioned use of Penal Code section 32, the accessory statute, to mete out felony punishment for a witness who merely opts to remain silent (as distinguished from a witness who affirmatively tells some falsehood in a police interview or while on the witness stand to throw the police or the jury off track). Indeed, while I cannot claim to have conducted a fully exhaustive survey, I have discovered no court in any jurisdiction nationwide that has ever sanctioned this sort of an accessory after the fact prosecution. The oddity of today's decision is no accident, nor is it a manifestation of the old adage that there must be a first time for everything. It is rather a product of well-intentioned but flawed legal reasoning that courts have heretofore avoided: Believing the statutorily authorized criminal penalty for refusing to testify (six months in jail) is too light a punishment for refusing to testify against defendants charged with murder, the majority blesses the invocation of Penal Code section 32, which imposes a higher penalty. As I shall discuss, however, authority dating back at least 50 years explains that resort for what might be viewed as overly light penalties for contumacious witnesses must be to the legislative process. A prosecuting office's decision to type up felony charges using a statute ill suited to the task is no adequate substitute, and the majority errs by refusing to say so.

These are just brief excerpts; if you're interested, you can read the full opinions.

UPDATE: Prof. Charles Weisselberg notes that the California Supreme Court has agreed to rehear the case; thanks, and sorry I didn't notice that originally.