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 deprecation warnings due to invalid escape sequences. #410

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tirkarthi
Copy link

Fixes #409

@jorenham
Copy link

@DenisCarriere Would you mind merging this? It is but a one-liner.

@DavidMertz
Copy link

I am experiencing the same issue, with Python 3.12. I utilize usaaddress-scourgify which included gocoder as a dependency. Running a FastAPI server that utilizes this, I've recently seen:

% uv run uvicorn app.main:app --reload
INFO:     Will watch for changes in these directories: ['/home/dmertz/git/SEIU/ada-etl']
INFO:     Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit)
INFO:     Started reloader process [214130] using WatchFiles
/home/dmertz/git/SEIU/ada-etl/.venv/lib/python3.12/site-packages/geocoder/uscensus.py:36: SyntaxWarning: invalid escape sequence '\d'
  match = re.search('^\d+', self.address, re.UNICODE)

I'm not sure why I've seen this syntax warning only recently. Perhaps it got promoted to SyntaxWarning. I think I just recently updated by 3.12.7 from an earlier 3.12, which might have added more checks.

I'd love it if the merge can be made.

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

Successfully merging this pull request may close these issues.

Deprecation warning due to invalid escape sequences in Python 3.7
3 participants