Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: add r strings for regex escape#313

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gabor-boros merged 1 commit intomasterfromgabor-boros-patch-1
May 22, 2025
Merged

Conversation

gabor-boros
Copy link
Member

Reason for the change
If applicable, link the related issue/bug report or write down in few sentences the motivation.

Description
A clear and concise description of what did you changed and why.

Code examples
If applicable, add code examples to help explain your changes.

Checklist

References
Anything else related to the change e.g. documentations, RFCs, etc.

@lsabi
Copy link
Contributor

I'm a little confused about the interpretation/syntax ofregex in python.

According tohttps://stackoverflow.com/questions/2241600/python-regex-r-prefix, the special characters need to be escaped, if the regex is prefixed withr (e.g. r'\w') in order to match something else than the literal string\w. Thus, it should be r\\w.

Therefore, also theregex need to be changed, in order to obtain the same result, don't they?

@gabor-borosgabor-boros deleted the gabor-boros-patch-1 branchMay 21, 2025 18:20
@gabor-borosgabor-boros restored the gabor-boros-patch-1 branchMay 22, 2025 06:06
@gabor-boros
Copy link
MemberAuthor

@lsabi We do want to use the regex\w that is matching for the word meta character. We do not want to escape it.

@gabor-borosgabor-boros merged commit339cd9a intomasterMay 22, 2025
@gabor-borosgabor-boros changed the titlerefactor: add r strings for regex escapefix: add r strings for regex escapeMay 22, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@gabor-boros@lsabi

[8]ページ先頭

©2009-2025 Movatter.jp