My program looks something like this:
import re # Escape the string, in case it happens to have re metacharacters my_str = \"The quick brown fox jumped\" esc
Just try import regex as re instead of import re.
import regex as re
import re