8000 Subtraction of 2 lists in jolt - Problem with the demo · Issue #1279 · bazaarvoice/jolt · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Subtraction of 2 lists in jolt - Problem with the demo #1279
Open
@LucaBiscotti

Description

@LucaBiscotti

Hello,
I was trying to create a jolt that does the subtraction between 2 lists, like for example:
a:[1,2,3]and
b:[1,2]so that
c=a-b -> c:[3]

While attempting to solve this, I noticed that the demo server was constantly going down. I tried opening it on another PC, and as soon as I ran my JOLT transformation, the whole thing would result in a 500 error, as if my JOLT spec was causing it.

Part of the spec I came up with is the following:

[
  {
    "operation": "shift",
    "spec": {
      "a": {
        "*": {
          "@0": "c[&1].@0"
        }
      },
      "b": "b"
    }
  },
  {
    "operation": "shift",
    "spec": {
      "b": {
        "*": {
          "@(2,c)": {
            "*": {
              "@3": {         // this line may cause the demo crash
                "@": "x"      // this line too
              }
            }
          }
        }
      }
    }
  }
]

I’m not sure if it’s just a coincidence that the demo crashes every time I run this JOLT transformation. If not, how can this issue be resolved—either the demo problem or the subtraction logic?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0