Mamdani's success demonstrates that there is now a viable electoral path for socialist candidates.