This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients abarry, asmeurer, ncoghlan, r.david.murray, rhettinger, serhiy.storchaka
Date 2019-06-14.06:20:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
In the particular case of pyparsing there was a bug in the docstring.

     def sub(self, repl): 
         Return Regex with an attached parse action to transform the parsed 
         result as if called using `re.sub(expr, repl, string) <>`_. 
             make_html = Regex(r"(\w+):(.*?):").sub(r"<\1>\2</\1>") 
             print(make_html.transformString("h1:main title:")) 
             # prints "<h1>main title</h1>" 

\1 and \2 were interpreted as control characters U+0001 and U+0002, so the user could see 

        make_html = Regex(r"(\w+):(.*?):").sub(r"<^A>^B</^A>")


        make_html = Regex(r"(\w+):(.*?):").sub(r"<☺>☻</☺>")


        make_html = Regex(r"(\w+):(.*?):").sub(r"<></>")

depending on the output device.

So this examples proves the usefulness of the new warning.
Date User Action Args
2019-06-14 06:20:31serhiy.storchakasetrecipients: + serhiy.storchaka, rhettinger, ncoghlan, r.david.murray, abarry, asmeurer
2019-06-14 06:20:31serhiy.storchakasetmessageid: <>
2019-06-14 06:20:31serhiy.storchakalinkissue32912 messages
2019-06-14 06:20:30serhiy.storchakacreate