Serhiy Storchaka added the comment: Ah, how can I missed this catch?
The simplest way is just move "-" to the start or the end of character list. The most error-proof way is to use re.escape(). ---------- components: +Library (Lib) keywords: +easy -3.5regression nosy: +demian.brecht stage: -> needs patch type: -> behavior _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue26302> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com