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

SyntaxWarning with pyspf 2.0.14 and python 3.12.x #45

Open
fechnert opened this issue Feb 6, 2025 · 3 comments
Open

SyntaxWarning with pyspf 2.0.14 and python 3.12.x #45

fechnert opened this issue Feb 6, 2025 · 3 comments

Comments

@fechnert
Copy link

fechnert commented Feb 6, 2025

While using pyspf==2.0.14 with python 3.12.x i get the following syntax warning in the shell, which complains about a docstring in the spf.py file.

/usr/local/lib/python3.12/site-packages/spf.py:1724: SyntaxWarning: invalid escape sequence '\d'
  """Quote the value for a key-value pair in Received-SPF header field
@kytta
Copy link

kytta commented Feb 6, 2025

This happened with upgrade to Python 3.12, btw. The DeprecationWarning on unsupported escape sequences was "upgraded" to a SyntaxWarning, which is why it's now always visible. See changelog and python/cpython#98401.

Looks like this will become an error in one of the future Python versions

@fechnert
Copy link
Author

fechnert commented Feb 6, 2025

This could easily be fixed by making the docstring a raw one. I will provide a PR this evening.

@fechnert fechnert changed the title SyntaxWarning with pyspf 2.0.14 SyntaxWarning with pyspf 2.0.14 and python 3.12.x Feb 6, 2025
@fechnert
Copy link
Author

fechnert commented Feb 6, 2025

I just saw this was fixed by #43

When can we expect a new version coming out? :)

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

2 participants