-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Extract full parameter name when using dots in bracket notation. #4880
Extract full parameter name when using dots in bracket notation. #4880
Conversation
The following is the coverage report on the affected files.
|
4237895
to
1ba1674
Compare
The following is the coverage report on the affected files.
|
/assign @imjasonh |
1ba1674
to
18d843b
Compare
The following is the coverage report on the affected files.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: vdemeester The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
/test pull-tekton-pipeline-integration-tests |
There's now some overly aggressive validation of previously valid params, that rejects the otherwise valid
|
Hmm. Is the rule of using Alternatively, we can choose to not throw an error at all. But in that case, |
I'd probably say only |
18d843b
to
2b06148
Compare
Thanks @imjasonh , I updated the code to reflect this. Since we are unsure of other prefixes, I am not throwing an error so that I don't break existing code. |
The following is the coverage report on the affected files.
|
/retest |
2b06148
to
01290d8
Compare
The following is the coverage report on the affected files.
|
01290d8
to
9761240
Compare
The following is the coverage report on the affected files.
|
9761240
to
0622ebe
Compare
The following is the coverage report on the affected files.
|
Prior to this, when using `$params["<NAME>"]` or `$params['<NAME>']`, if `NAME` contained `dots(.)` (eg. `org.foo.blah`), only `org` would be extracted, instead of `org.foo.blah`. This PR now properly fetches the entire string and throws an error if using `dots (.)` without `single` or `double` quotes. The following references show whats valid and whats not: `$params.org.foo.blah` : Not Valid: the webhook will throw a validation error. `$params["org.foo.blah"]`: Valid `$params['org.foo.blah']`: Valid
0622ebe
to
6f48ed1
Compare
The following is the coverage report on the affected files.
|
@imjasonh All the integration tests now pass. I think it should be ok now 🤞. |
/lgtm This seems to work in my downstream tests. Thanks for fixing this! 👍 |
Prior to this, when using
$params["<NAME>"]
or$params['<NAME>']
,if
NAME
containeddots(.)
(eg.org.foo.blah
), only the first part (ie.org
) would beextracted, instead of the entire name
org.foo.blah
. This PR now properly fetches theentire name and throws an error if using
dots (.)
withoutsingle
or
double
quotes.The following references show whats valid and whats not:
$params.org.foo.blah
: Not Valid: the webhook will throw a validation error.$params["org.foo.blah"]
: Valid: Properly extracts the entireNAME
(org.foo.blah
).$params['org.foo.blah']
: Valid: Properly extracts the entireNAME
(org.foo.blah
).Changes
Submitter Checklist
As the author of this PR, please check off the items in this checklist:
functionality, content, code)
(if there are no user facing changes, use release note "NONE")
Release Notes