jmespath / jmespath/jmespath.js

The system consider path as valid if the closed apostrophe is missing

Open
#75 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
847
Forks
101
PR merge metrics
No merged PRs in 30d

Description

Javascript JMESPath library can allow write filter expression without closed apostrophe sign.

For example, in expression
`a == 'foo d`
for json object
`{"a": "foo d", "b": "bar"}`
the result will be true and expression can valid.

But, if we try apply it expression in Java JMESPath library, it will be thrown exception:
`io.burt.jmespath.parser.ParseException: Unable to compile expression "a == 'foo d": syntax error token recognition error at: ''foo d' at position 5, syntax error mismatched input '' expecting {'!', '(', '*', '[', '{', '[?', '@', '`', RAW_STRING, JSON_CONSTANT, NAME, STRING} at position 11`
In my opinion, it is bug of Javascript JMESPath library parser, because in JMESPath documentation nowhere write about user can missed closed apostrophe sign.

Using versions:
Javascript JMESPath library: 0.15.0
Java JMESPath library: 0.5.0

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.