Error 402840, Insert Item - path in error description message

Issue #71 resolved
Ivan Yakushchenko created an issue

When Error 402840 occurs during Set Item, path is truncated ($ sign is removed, but . is left, so it looks like this):

Although, path value is $.TestNode.Value.

Maybe it will be better either to display full path, or if not - then also remove first . in the path value.

Comments (2)

  1. James Powell repo owner

    .TestNode.Value is the true path used internally. I externally adopt the $ from other JSONpath implementations, who originally get it in analogy to Xpath for XML. But XML has a meaningful root “document” but JSON is fully recursive, so it doesn’t make sense to use it internally.

    Note that removing the dot causes lots of possible ambiguities, so I see no value in that.

  2. Log in to comment