str.rstrip in python