  We report the discovery of a low-mass $z=5.200\pm 0.002$ galaxy that is in
the process of ceasing its star formation. The galaxy, MACS0417-z5PSB, is
multiply imaged with magnification factors $\sim40$ by the galaxy cluster MACS
J0417.5-1154, observed as part of the CAnadian NIRISS Unbiased Cluster Survey
(CANUCS). Using observations of MACS0417-z5PSB with a JWST/NIRSpec Prism
spectrum and NIRCam imaging, we investigate the mechanism responsible for the
cessation of star formation of the galaxy, and speculate about possibilities
for its future. Using spectrophotometric fitting, we find a remarkably low
stellar mass of $\rm{M_*}=4.3\pm^{0.9}_{0.8} \times 10^{7} \rm{M_{\odot}}$,
less than 1% of the characteristic stellar mass at $z\sim5$. We measure a
de-lensed rest-UV half-light radius in the source plane of $30\pm^{7}_{5}$ pc,
and measure a star formation rate from H$\alpha$ of $0.14\pm^{0.17}_{0.12}$
$\rm{M_{\odot}/yr}$. We find that under the assumption of a double power law
star formation history, MACS0417-z5PSB has seen a recent rise in star
formation, peaking $\sim10-30$ Myr ago and declining precipitously since then.
Together, these measurements reveal a low-mass, extremely compact galaxy which
is in the process of ceasing star formation. We investigate the possibilities
of mechanisms that have led to the cessation of star formation in
MACS0417-z5PSB, considering stellar and AGN feedback, and environmental
processes. We can likely rule out an AGN and most environmental processes, but
leave open the possibility that MACS0417-z5PSB could be a star forming galaxy
in the lull of a bursty star formation history.
