Why won't this flow import?

In a github issue the OP is posting flows that validate ok in https://jsonlint.com but won't import as node red says it is not valid JSON.

Could someone who knows about such things indicate what the problem is? I suspect it may be due to embedded non-printable characters, or something similar. The question then is, should node-red be able to import it?

[
    {
        "id": "a17e320916ab3b9b",
        "type": "tab",
        "label": "Энергометр",
        "disabled": false,
        "info": ""
    },
    {
        "id": "b29ff552a7bdcaf4",
        "type": "ui-chart",
        "z": "a17e320916ab3b9b",
        "g": "f16661260a2f9b01",
        "group": "4ecca468c23df954",
        "name": "Монитор",
        "label": "Мониторинг напряжения, потребления, потерь и частоты онлайн",
        "order": 1,
        "chartType": "bar",
        "category": "seriesMon",
        "categoryType": "property",
        "xAxisLabel": "",
        "xAxisProperty": "topic",
        "xAxisPropertyType": "msg",
        "xAxisType": "category",
        "xAxisFormat": "dd.LL",
        "xAxisFormatType": "custom",
        "xmin": "",
        "xmax": "",
        "yAxisLabel": "",
        "yAxisProperty": "valuesMon",
        "yAxisPropertyType": "property",
        "ymin": "0",
        "ymax": "600",
        "bins": 10,
        "action": "replace",
        "stackSeries": false,
        "pointShape": "circle",
        "pointRadius": "2",
        "showLegend": true,
        "removeOlder": "5",
        "removeOlderUnit": "604800",
        "removeOlderPoints": "",
        "colors": [
            "#0095ff",
            "#ff0000",
            "#ff7f0e",
            "#2ca02c",
            "#a347e1",
            "#d62728",
            "#ff9896",
            "#9467bd",
            "#c5b0d5"
        ],
        "textColor": [
            "#666666"
        ],
        "textColorDefault": true,
        "gridColor": [
            "#e5e5e5"
        ],
        "gridColorDefault": true,
        "width": 6,
        "height": "5",
        "className": "",
        "interpolation": "smooth",
        "x": 1460,
        "y": 340,
        "wires": [
            []
        ]
    },
    {
        "id": "4ecca468c23df954",
        "type": "ui-group",
        "name": "Онлайн",
        "page": "d8ffe29d78eeda2b",
        "width": 6,
        "height": 1,
        "order": 1,
        "showTitle": true,
        "className": "",
        "visible": "true",
        "disabled": "false",
        "groupType": "default"
    },
    {
        "id": "d8ffe29d78eeda2b",
        "type": "ui-page",
        "name": "Мониторинг",
        "ui": "b3cc25479f46b68b",
        "path": "/monitoring",
        "icon": "home",
        "layout": "grid",
        "theme": "ec10442445c8ea89",
        "breakpoints": [
            {
                "name": "Default",
                "px": "0",
                "cols": "3"
            },
            {
                "name": "Tablet",
                "px": "576",
                "cols": "6"
            },
            {
                "name": "Small Desktop",
                "px": "768",
                "cols": "9"
            },
            {
                "name": "Desktop",
                "px": "1024",
                "cols": "12"
            }
        ],
        "order": 21,
        "className": "",
        "visible": "true",
        "disabled": "false"
    },
    {
        "id": "b3cc25479f46b68b",
        "type": "ui-base",
        "name": "My Dashboard",
        "path": "/dashboard",
        "appIcon": "",
        "includeClientData": true,
        "acceptsClientConfig": [
            "ui-notification",
            "ui-control"
        ],
        "showPathInSidebar": false,
        "headerContent": "page",
        "navigationStyle": "default",
        "titleBarStyle": "default",
        "showReconnectNotification": true,
        "notificationDisplayTime": 1,
        "showDisconnectNotification": true,
        "allowInstall": true
    },
    {
        "id": "ec10442445c8ea89",
        "type": "ui-theme",
        "name": "Default Theme",
        "colors": {
            "surface": "#ffffff",
            "primary": "#0094CE",
            "bgPage": "#eeeeee",
            "groupBg": "#ffffff",
            "groupOutline": "#cccccc"
        },
        "sizes": {
            "density": "default",
            "pagePadding": "12px",
            "groupGap": "12px",
            "groupBorderRadius": "4px",
            "widgetGap": "12px"
        }
    },
    {
        "id": "8443b8864894bd4f",
        "type": "global-config",
        "env": [],
        "modules": {
            "@flowfuse/node-red-dashboard": "1.29.0"
        }
    }
]

imports fine for me on Win + Chrome (it imports to a separate tab)

Do you have errors in the browsers console?

1 Like

Hmm, that's odd. After pasting it here and re-copying it, it is ok.

To see the problem it seems necessary to get it directly from github. I can't work out how to directly reference an individual comment on github, but it is the flow posted on 11/10/25 09/10/25 in the link posted above.

Edit, corrected date

This one --> New version of the diagrams all curved and oblique!! · Issue #1885 · FlowFuse/node-red-dashboard · GitHub

to get share link, click on the date "5 days ago":

for what it's worth, it doesn't work with the browser-red:

I see the problem, I think. The flow has UTF8 non-breaking spaces, 0xC2A0, dotted through it. Whether node-red should cope with that I don't know. I think the supplier of the flow is manually creating the flow file.

2 Likes

Manually.... or getting something else to generate it?

I am not entirely sure, it has been difficult to determine that. It doesn't really matter I don't think. The question is whether node-red should say that it is invalid JSON when (apparently) it is not invalid.

Not sure if this is throwing it?
these chars are not present here -> Why won't this flow import?

EDIT


Oh you found it (its early) :melting_face:

This looks very much like ai generated flows are being used. There are many posts around the web of ai inserting non printable characters in code.

So AI can generate flows? Yes, but you should not use them. Flow JSON is not schema driven nor is it schema validated. It is very easy for a bad combination of values to get in the flows and crash your system.

is this watermarking AI content by any chance?

Some say yes. IDK. Its pretty weak TBF.

What's the alternative with text only content? it's not like you can create an ascii graphic between the lines :wink:

but I'm sure there will soon be an app for that ....

It turns out that the guy has been manually editting the flow file, so most likely his editor converted the spaces to unicode.