python only assign if not none