The democratic socialist will have to overcome a divided Democratic Party and Republican President Donald Trump, who has threatened to punish the city.