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

Validate "path matches" conditions as regular expressions #78

Merged
merged 2 commits into from Mar 17, 2021

Conversation

willbarton
Copy link
Member

@willbarton willbarton commented Mar 17, 2021

Because "path matches" conditions can be any valid regular expression, this change simply uses re.compile() to validate them.

Previously they were validated as URL paths, without querystring or URL scheme-matching characters allowed. This warned on some valid regular expressions that it shouldn't have.

This fix is what @chosak suggested in, and fixes #77.

Because "path matches" conditions can be any valid regular expression, this change simply uses `re.compile()` to validate them.

Previously they were validated as URL paths, without querystring or URL scheme-matching characters allowed. This warned on some valid regular expressions that it shouldn't have.

This fix is what @chosak suggested in #77.
@willbarton willbarton requested review from chosak and a team March 17, 2021 14:03
Copy link
Contributor

@Scotchester Scotchester left a comment

Choose a reason for hiding this comment

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

Makes sense to me.

@willbarton willbarton merged commit 9eeec66 into main Mar 17, 2021
@willbarton willbarton deleted the fix-path-validator branch March 17, 2021 15:27
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.

Path condition validator warns on valid regular expressions
2 participants