I am not sure why this is not working. Perhaps I am missing something with Python regex.
Here is my regex and an example string of what I want it to match too:
You have to mark the string as a raw string, due to the \ in there, by putting an r in front of the regex:
\
r
m = re.match(r"<(.*)>phone</\1>", "<bar>phone</bar>")