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

remove deprecation warnings #63

Merged
merged 1 commit into from
Feb 9, 2022
Merged

remove deprecation warnings #63

merged 1 commit into from
Feb 9, 2022

Conversation

jvllmr
Copy link
Contributor

@jvllmr jvllmr commented Feb 9, 2022

escape sequences are suppressed by creating regex strings, flags have to be at the beginning of regex: gboeing/osmnx#285

fixes #62
fixes #59

escape sequences are suppressed by creating regex strings, flags have to be at the beginning of regex: gboeing/osmnx#285
@@ -354,7 +354,7 @@ def __init__(self, safe_tags=SAFE_TAGS, safe_attrs=SAFE_ATTRS,
# IE6 <http://openmya.hacker.jp/hasegawa/security/expression.txt>
# 7) Particular bit of Unicode characters
_URL_FINDITER = re.compile(
u'[Uu][Rr\u0280][Ll\u029F]\s*\(([^)]+)').finditer
u'[Uu][Rr\u0280][Ll\u029F]%s*\(([^)]+)' % (r'\s')).finditer
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the only way I could easily keep the unicode string for python2 support.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A bit ugly, but it works!

Copy link
Contributor

@hodgestar hodgestar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

It would be nice to be able to raise errors when these warnings are generated, but that probably requires updating genshi to use pytest, so best left for a separate PR.

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.

0.7.6: pytest warnings Fix pytest warnings
2 participants