I mistakenly focused on (ii) Exception (I), your case is actually in (ii) Exception (III), it clearly says you have two years to sell after moving out.
https://www.law.cornell.edu/uscode/text/26/121?
(ii)ExceptionsThe term “period of nonqualified use” does not include—
(I)
any portion of the 5-year period described in subsection (a) which is after the last date that such property is used as the principal residence of the taxpayer or the taxpayer’s spouse,
(II)
any period (not to exceed an aggregate period of 10 years) during which the taxpayer or the taxpayer’s spouse is serving on
qualified official extended duty (as defined in subsection (d)(9)(C)) described in clause (i), (ii), or (iii) of subsection (d)(9)(A), and
(III)
any other period of temporary absence (not to exceed an aggregate period of 2 years) due to change of employment, health conditions, or such other unforeseen circumstances as may be specified by the Secretary.