I found a documentation bug in textlib.py:

In the beginning of replaceExcept() the line
       old             - a compiled regular expression
should be
       old             - a compiled or uncompiled regular expression
(ReplaceExcept will compile it if it has the type string or unicode.)

--
Bináris