Open nicho2 opened 5 years ago
[Python][raw string]bad pattern with raw string
raw string is not correctly used
2.4.4 it is a regression
previous version: re.search('^[\w\s:.,_-]*$', "UNITEST") answer:<_sre.SRE_Match object at 0x132DE800>
this version: re.search(r'^[\w\s:.,_-]*$', "UNITEST") no match because raw string is used but too more \
the good way is : re.search(r'^[\w\s:.,_-]*$', "UNITEST")
@nicho2 Can you read your description again, looks something is wrong. No match regex is working one.
[Python][raw string]bad pattern with raw string
Description
raw string is not correctly used
Swagger-codegen version
2.4.4 it is a regression
Swagger declaration file content or url
Command line used for generation
Steps to reproduce
previous version: re.search('^[\w\s:.,_-]*$', "UNITEST") answer:<_sre.SRE_Match object at 0x132DE800>
this version: re.search(r'^[\w\s:.,_-]*$', "UNITEST") no match because raw string is used but too more \
Related issues/PRs
Suggest a fix/enhancement
the good way is : re.search(r'^[\w\s:.,_-]*$', "UNITEST")