How to properly handle re.error exceptions in pylint config argument transformers?