Shows up in the variable selector but also says not found

This variable shows up in the variable selector side panel. But when I click on it, it shows up on the right as an error saying “Not Found”. This is happening with all of the input data variables, but not with other variables

If you run it, does it still resolve to undefined (not found)? or does it resolve to the right value?

It’s strange… it actually does run correctly. but even after running it still says “[not found]”

Are you still having the issue?

Yes. The workflow works but it looks like it’s broken for some reason

@jan do you know if this is a known issue with the expression editor?

No can sadly not explain that right now. Can you share a workflow with some mock data which allows us to reproduce that @timconnorz as I am not able to do that.

I created the following test workflow but it works as expected:

Here’s an example. If you go to the sendgrid node and try to set one of the values as a reference to the input data from IF node, it says “not found”

{
  "name": "Send Follow-up Emails copy",
  "nodes": [
    {
      "parameters": {},
      "name": "Start",
      "type": "n8n-nodes-base.start",
      "typeVersion": 1,
      "position": [
        390,
        190
      ]
    },
    {
      "parameters": {
        "conditions": {
          "string": [
            {
              "value1": "={{$node[\"IF\"].json[\"fields\"][\"Stage\"]}}",
              "value2": "Approved / Pending Onboard"
            },
            {
              "value1": "={{$node[\"IF\"].json[\"fields\"][\"Info\"]}}",
              "value2": "Onboard email sent"
            }
          ]
        }
      },
      "name": "IF1",
      "type": "n8n-nodes-base.if",
      "typeVersion": 1,
      "position": [
        840,
        190
      ],
      "alwaysOutputData": true,
      "notes": "split route by the stage"
    },
    {
      "parameters": {
        "resource": "mail",
        "fromEmail": "[email protected]",
        "fromName": "Tim from Pearl",
        "toEmail": "={{$json[\"fields\"][\"Email\"]}}",
        "dynamicTemplate": true,
        "templateId": "d-5c1291166fb04e3194451fed8b1bfbff",
        "dynamicTemplateFields": {
          "fields": [
            {
              "key": "firstName",
              "value": "={{$json[\"fields\"][\"First Name\"]}}"
            },
            {
              "key": "companyName",
              "value": "={{$json[\"fields\"][\"Company Name\"]}}"
            }
          ]
        },
        "additionalFields": {}
      },
      "name": "SendGrid",
      "type": "n8n-nodes-base.sendGrid",
      "typeVersion": 1,
      "position": [
        1030,
        180
      ],
      "notesInFlow": true,
      "credentials": {
        "sendGridApi": "sendgrid key"
      },
      "disabled": true,
      "notes": "Send onboarding call follow-up"
    },
    {
      "parameters": {
        "functionCode": "const fields = { \"Email\": \"[email protected]\", \"First Name\": \"test2\", \"Is your company permanently remote?\": \"Yes, open to all countries\", \"How much could you pay for a successful hire?\": \"10,000\", \"How large is your current team?\": \"500\", \"Company Name\": \"Test 2\", \"Company Home Page\": \"https://example.com\", \"Stage\": \"Approved / Pending Onboard\", \"Info\": \"Onboard email sent\", \"Last Name\": \"Testerson\", \"Last Email Sent\": \"2021-07-06T06:37:00.000Z\", \"ID\": \"Test 2\", \"Signup Date\": \"2021-08-03\", \"Last Stage Update\": \"2021-08-03T05:46:37.000Z\", \"Full Name\": \"test2 Testerson\", \"recordID\": \"recsdjoqsqOks\", \"is\": 1 }\n\nreturn [{ json: {fields}}];"
      },
      "name": "Function",
      "type": "n8n-nodes-base.function",
      "typeVersion": 1,
      "position": [
        610,
        190
      ]
    }
  ],
  "connections": {
    "IF1": {
      "main": [
        [],
        [
          {
            "node": "SendGrid",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Start": {
      "main": [
        [
          {
            "node": "Function",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Function": {
      "main": [
        [
          {
            "node": "IF1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "errorWorkflow": "7",
    "timezone": "America/Los_Angeles"
  },
  "id": 8
}

Even though it is clearly there

Ah yes, sorry. That is sadly a known issue. Currently do expressions in the Editor only resolve values correctly from the first output of a node. As you have the node connected to the second output (“false” of the IF-Node) does it sadly not get displayed correctly right now.

A temporary workaround is to add another node in between like a NoOp-Node.

Ok thanks jan!

strange, i’ve also just noticed this issue in one of my flows