We study the Josephson effect in a quantum spin Hall system coupled to a localized magnetic impurity. As a consequence of the fermion parity anomaly, the spin of the combined system of impurity and spin-Hall edge alternates between half-integer and integer values when the superconducting phase difference across the junction advances by $2pi$. This leads to characteristic differences in the splittings of the spin multiplets by exchange coupling and single-ion anisotropy at phase differences, for which time-reserval symmetry is preserved. We discuss the resulting $8pi$-periodic (or $mathbb{Z}_4$) fractional Josephson effect in the context of recent experiments.