Fix Python 3 failures comparing None to strings