Launching node-red(error of infinite loop)

#1

Hi,
when I start node-red, I see this error:

0 Likes

#2

I would guess that you have some code that has an infinite loop somewhere.

However, you need to share details about your environment (node.js, node-red,etc version numbers, OS, platform).

Also, sharing your flow might be helpful.

1 Like

#3

yes i have an infinite loop somewhere, I know where is this error but how can I delete the node through cli or file ?

0 Likes

#4

Ah, sorry, of course.

If you are using the latest version of Node-RED, you should be able to restart it using the safe option so that the flows don't automatically start.

1 Like

#5
  • Add --safe mode flag to allow starting without flows running. This can be used if a flow is causing Node-RED to crash - starting in safe mode will allow the editor to be used to modify the flow and then deploy the change to take it out of safe mode.
1 Like

#6

I have version 0.19.6, where i put --safe mode

0 Likes

#7

Unfortunately it only came in v0.20

0 Likes

#8

As @ukmoose says, that option was only added in 0.20.

You can either hand-edit your flow file, identify the offending node and delete it, or move the flow file to a new location so Node-RED starts with a blank set of flows. You can then import your old flows bit by bit.

If you aren't sure where your flow file is, Node-RED logs the full path to the file its using when it starts up.

1 Like

#9

thank you, it works now when i upgrade NR to v0.20 and use the safe mode

1 Like