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
Fixes #11449: Allow variable as directive parameters in regexp validated inputs #1757
Conversation
Close for now, this needs to be tested |
@@ -53,14 +53,14 @@ case class RegexConstraint(pattern: String, errorMsg: String) extends HashcodeCa | |||
|
|||
val compiled = Pattern.compile(pattern) | |||
|
|||
val variablePattern = Pattern.compile(".*\\$\\{.*\\}.*") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i fear it may be a bit too eager
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
well, actually, i can't see why it should be an issue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes we don't want to analyze it deeply do it does not need to be perfect matches for cases i tested ... (one var, two vars, var inside a var ... )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated the regexp so it's less eager (added ? after * so it matches as less possible)
Commit modified |
5d5e881
to
0da78d3
Compare
Commit modified |
0da78d3
to
d26155d
Compare
OK, merging this PR |
https://www.rudder-project.org/redmine/issues/11449