[issue35653] All regular expression match groups are the empty string

2019-01-05 Thread adiba
Change by adiba : -- nosy: -adiba, ezio.melotti, mrabarnett ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue35653] All regular expression match groups are the empty string

2019-01-03 Thread Matthew Barnett
Matthew Barnett added the comment: Look at the spans of the groups: >>> import re >>> re.search(r'^(?:(\d*)(\D*))*$', "42AZ").span(1) (4, 4) >>> re.search(r'^(?:(\d*)(\D*))*$', "42AZ").span(2) (4, 4) They're telling you that the groups are matching twice (because of the outer *). The first t

[issue35653] All regular expression match groups are the empty string

2019-01-03 Thread adiba
New submission from adiba : This is the regular expression: ^(?:(\d*)(\D*))*$ This is the test string: 42AZ This is the expectation for the match groups: ('42', 'AZ') This is the actual return value: ('', '') https://gist.github.com/adiba/791ba943a1102994d43171dc98aaecd0 -- components: