jsonpath
jsonpath copied to clipboard
JsonPath engine written in Rust. Webassembly and Javascript support too
Cloning the SelectorMut is necessary when storing them for later use. This PR allows SelectorMuts to be cloned. Cred: @lfarrel6
Filter might return duplicate results when the internal objects are similar. e.g. input JSON both objects have name == `{"first":"A","middle":"A"}` ```JSON [{{"name":{"first":"A","middle":"A"},"rank":8},{"name":{"first":"A","middle":"A"},"rank":90}] ``` When running: ``` $[?($.name.first=="A")] ``` The following...
Fix #89
Path: `$[*][?(@.inner.for.inner=='u8')]` JSON: ```json { "0:4": { "id": "0:4", "inner": { "for": {"inner": "u8", "kind": "primitive"} } } } ``` `jsonpath` matches to `[]` Expected: ```json [ { "id" :...
Hi, I discovered the following panic while using `SelectorMut::remove`: ``` thread 'main' panicked at 'index out of bounds: the len is 1 but the index is 2', /home/mohmann/.cargo/registry/src/github.com-1ecc6299db9ec823/jsonpath_lib-0.3.0/src/select/mod.rs:814:56 stack backtrace:...
Path such as `$.store.book[0]category` Does not throw an error and is silently ignoring the surplus text `category` beyond the `]` And is parsed as `$.store.book[0]` Can be demonstrated also on...
Adding a test such as the following, fails when a filter contains an `OR` expression with one of its operands being compared to a none-existing value, e.g., Slightly modifying an...
Today the code assumes the underline json structure is serde_json::Value. We have a situation where this is not the case and we need to work with a custom structure. We...