-
Notifications
You must be signed in to change notification settings - Fork 89
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
Enclose field names containing literals in quotes #61
base: master
Are you sure you want to change the base?
Conversation
When creating the text representation of a path, field names that contain lexer literals (like a period ".') should be enclosed in quotes (or brackets). The proposed fix only adds quotes if needed (as opposed to alway). This avoids changing current paths/behavior drastically since it seems no one has run into this so far. Change-Id: Ia6e01f9b8218182aa61d3c39b16d4bfb57e4f593
Since the pull request for changes has not been merged, enable differentiating which jsonpath-ng is installed. Change-Id: If42cb8aafbb79c8bc7b07a54473eb6ba8da9f50e
Change-Id: Ifb2eab1ebf9151c14b533cf13ef20707bb3ada19
@michaelmior Could you please take a look at this pull request? I fixed trivial merge conflicts recently, let me know if you have other suggestions. |
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.
Overall looks good. See a few minor suggested changes.
Revert version change, get rid of variable for literals. Change-Id: I381d0a77c6832e96bb0c1f28afc15640c6e953f4
Thanks! Merged in 4c1effd |
Change-Id: Ibdaf122bf2fcd762540dce1437373b166b97c910
Change-Id: Id767180b08a15aa6769f50dac43d09ceedf2875d
Change-Id: Id767180b08a15aa6769f50dac43d09ceedf2875d
Looking at this more closely, there are a couple cases that aren't handled here. For example, spaces and double quotes should be enclosed in single quotes also. Single quotes should also be escaped and then quoted. |
When creating the text representation of a path, field names that contain lexer literals (like a period ".') should be enclosed in quotes (or brackets).
The proposed fix only adds quotes if needed (as opposed to alway). This avoids changing current paths/behavior drastically since it seems no one has run into this so far.
Change-Id: Ia6e01f9b8218182aa61d3c39b16d4bfb57e4f593