node-red / nrlint

Node-RED Flow Linter
Apache License 2.0
36 stars 15 forks source link

Similar to #44

Open Steve-Mcl opened 2 months ago

Steve-Mcl commented 2 months ago

Current Behavior

Similar to #37 linter does not recognise variables generated by the function nodes imports

image

Expected Behavior

linter should include any variables created in the function nodes imports

Steps To Reproduce

Example flow

[
    {
        "id": "3dfba4cb62aa0313",
        "type": "function",
        "z": "6f432348c57a2fda",
        "name": "get free memory",
        "func": "msg.payload = os.freemem()\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [
            {
                "var": "os",
                "module": "os"
            }
        ],
        "x": 620,
        "y": 340,
        "wires": [
            [
                "888416a8bb047df7"
            ]
        ]
    }
]

Environment