Why eval(pathexp)
prints the input twice?
#1920
Unanswered
lucabalsanelli
asked this question in
Q&A
Replies: 1 comment
-
Eval-All can work a little weirdly, it does a cross function, perhaps even more unexpected when using This means it will load up both files, as two separate nodes; then it will run the eval expression against each node to get two path expressions (Which happen to be the same). Then it runs those two path expression against the two document nodes, and so you see 4 results. You may be better off just using the default 'eval'. In fact, since I added the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I was trying to understand Merge arrays of objects together, matching on a key from the manual and I noticed something strange to me.
We are given
sample.yml
andanother.yml
:If I do
I get
that is the output is duplicated. On the other hand, if I do
I get
that is I get just the expected objects. Why is that the case? Am I missing something?
Thanks,
Luca
Beta Was this translation helpful? Give feedback.
All reactions