Guido van Rossum added the comment: Mark, it looks like the replace_whitespace flag shouldn't be used with input containing newlines. __________________________________ Tracker <report at bugs.python.org> <http://bugs.python.org/issue1859> __________________________________