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

build: fix a few python string escape warnings #16449

Merged
merged 1 commit into from
Jul 25, 2024

Conversation

eqvinox
Copy link
Contributor

@eqvinox eqvinox commented Jul 23, 2024

When using a regex (or anything that uses \? escapes) in python, raw strings (r"content") should be used so python doesn't consume the escapes itself. Otherwise we get either broken behavior and/or SyntaxWarning: invalid escape sequence '\['

When using a regex (or anything that uses `\?` escapes) in python, raw
strings (`r"content"`) should be used so python doesn't consume the
escapes itself.  Otherwise we get either broken behavior and/or
`SyntaxWarning: invalid escape sequence '\['`

Signed-off-by: David Lamparter <[email protected]>
@frrbot frrbot bot added the bugfix label Jul 23, 2024
@donaldsharp donaldsharp merged commit 035542f into FRRouting:master Jul 25, 2024
14 checks passed
@eqvinox eqvinox deleted the py-invalid-escapes branch July 26, 2024 00:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants