A New York judge Friday upheld President-elect Donald Trump’s criminal conviction but signaled that he was inclined to spare him any punishment, a striking development in a case that had spotlighted an array of embarrassing misdeeds and imperiled the former and future president’s freedom.

The judge, Juan M. Merchan, indicated that he favored a so-called unconditional discharge of Trump’s sentence, a rare and lenient alternative to jail or probation. He set a sentencing date of Jan. 10, and ordered Trump to appear either in person or virtually.

An unconditional discharge would cement Trump’s status as a felon just weeks before his inauguration — he would be the first to carry that dubious designation into the presidency — even as it would water down the consequences for his crimes.