SyntaxFix
Write A Post
Hire A Developer
Questions
Your question contains the string literal "\b[A-Z]{2,}\b", but that \b will mean backspace, because there is no r-modifier.
"\b[A-Z]{2,}\b"
\b
Try: r"\b[A-Z]{2,}\b".
r"\b[A-Z]{2,}\b"