Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix DeprecationWarning: escape sequences for normalize_string() #10

Open
f-hafner opened this issue Sep 5, 2022 · 0 comments
Open

fix DeprecationWarning: escape sequences for normalize_string() #10

f-hafner opened this issue Sep 5, 2022 · 0 comments

Comments

@f-hafner
Copy link
Owner

f-hafner commented Sep 5, 2022

DeprecationWarning for normalize_string():

src/dataprep/helpers/functions.py:41
  /home/flavio/projects/mag_sample/src/dataprep/helpers/functions.py:41: DeprecationWarning: invalid escape sequence \w
    s = s.replace("[^\w\d]", " ", regex = True)

src/dataprep/helpers/functions.py:42
  /home/flavio/projects/mag_sample/src/dataprep/helpers/functions.py:42: DeprecationWarning: invalid escape sequence \s
    s = s.replace("\s+", " ", regex = True)

these should be replaced with r"[^\w\d]" and with r"\s+" respectively.

see also here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant