After the 2020 election, Trump should pardon Assange.
Why would Trump do that? (Serious question)
As mentioned, pardoning Assange will be politically unpopular. The best time to a politically unpopular move is immediately after an election because you are maximizing the time until you need to face voters again.
If Trump wins reelection, and only has a narrow majority in the house and senate, he might wish to wait until after the 2024 election because pardoning Assonge might inspire enough Republican congressmen to be upset enough so they become opposed to Trump's agenda.