oec-scripts
oec-scripts copied to clipboard
Use actual re.sub() regex-replace rather than str.replace(), since we…
… want to eliminate all varieties of whitespace from the Labels sent to Jira.
I noticed that the code to make a Label out of the alias name was evidently intending to remove all whitespace from the name, since spaces are not permitted in a Label on the Jira side. However, the str.replace() function recognizes only static strings, not character classes or other regex constructs; it was looking for literally backslash-s in the original text, so it would not even remove spaces. Since the "re" module is in the core library in both Python 2.x and 3.x, I propose importing that and using re.sub(). Thanks!
Hi @JeffSaxeVA, you can track the progress about the issue from this ticket