# "Error: ENOENT: no such file or directory" shows on log when opening DEBUG in new window

**URL:** <https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303>\
**Category:** General\
**Created:** [1 July 2020 11:42 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303 "2020-07-01T11:42:31Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [1 July 2020 11:42 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/1 "2020-07-01T11:42:31Z")

</div>

This happens in Node-RED v 1.0.6 and 1.1.0 - I didn't try it in earlier releases.  
Reproducible on OS: macOS v10.14.6 and raspberry pi (buster)

Open the editor and go to the `debug` tab down the bottom right is the 'Open in new window' button. If you press it, the debug opens in the new window. If I look in the log I see:

```auto
1 Jul 07:32:33 - [info] Started flows
Error: ENOENT: no such file or directory, stat '/usr/local/lib/node_modules/node-red/node_modules/@node-red/nodes/core/common/lib/debug/locales/editor'
Error: ENOENT: no such file or directory, stat '/usr/local/lib/node_modules/node-red/node_modules/@node-red/nodes/core/common/lib/debug/locales/node-red'
Error: ENOENT: no such file or directory, stat '/usr/local/lib/node_modules/node-red/node_modules/@node-red/nodes/core/common/lib/debug/locales/jsonata'
Error: ENOENT: no such file or directory, stat '/usr/local/lib/node_modules/node-red/node_modules/@node-red/nodes/core/common/lib/debug/locales/infotips'

```

---

<div class="post-metadata">

**Author:** ![afelix](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/afelix/32/9743_2.png) [@afelix](https://discourse.nodered.org/u/afelix)\
**Post date:** [1 July 2020 13:09 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/2 "2020-07-01T13:09:25Z")

</div>

Highly interesting, as I was looking at this part of the core code some 2 hours ago. Just reproduced this on 1.0.6 on raspbian stretch, let me take a dive to see if I can find the source. I think I spot what's going on, let me do a quick check.

Edit: Yep found it. The popup window for the debugger is including the core's `red.js` as it needs it, which includes the `i18n` code to get translations. Here's the relevant part of the source located: [https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node\_modules/%40node-red/editor-client/src/js/i18n.js#L22-L36](https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node_modules/%40node-red/editor-client/src/js/i18n.js#L22-L36)  
Then, when trying to get those files, it tries to get them through the address created: [https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node\_modules/%40node-red/editor-client/src/js/i18n.js#L75](https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node_modules/%40node-red/editor-client/src/js/i18n.js#L75)  
Which then through a couple steps is resolved here: [https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node\_modules/%40node-red/runtime/lib/api/nodes.js#L364](https://github.com/node-red/node-red/blob/7a3ead8f3b4bc6cc0833c2b058ab9be1769e10eb/packages/node_modules/%40node-red/runtime/lib/api/nodes.js#L364)

Because of the non-root entry path, it somehow tries to resolve it in the directory that the debug window's popout files are located, and will fail to resolve the files in the i18n library as those paths do not exist. It appears the origin for all of this is on the apiRootUrl, but I'm not so sure yet on how to resolve this. Looks like a bug, and should probably be reported on Github.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [1 July 2020 13:28 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/3 "2020-07-01T13:28:18Z")

</div>

I'll open an issue and refer bck to your explaination!

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [1 July 2020 15:11 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/4 "2020-07-01T15:11:55Z")

</div>

Issue created on GitHub: [https://github.com/node-red/node-red/issues/2629](https://github.com/node-red/node-red/issues/2629)

---

<div class="post-metadata">

**Author:** ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)\
**Post date:** [23 August 2020 11:00 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/5 "2020-08-23T11:00:53Z")

</div>

I'm not sure if this is the same issue, but I've noticed the following error in the debug window:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/1/e19aafc0e678dac00f8874a8c4372f215c3cf3ab.png)

I'm running on Win 10, v1.1.2 of Node-RED.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [23 August 2020 11:40 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/6 "2020-08-23T11:40:12Z")

</div>

Try using NR 1.1.3

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [23 August 2020 11:49 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/7 "2020-08-23T11:49:08Z")

</div>

Hi @alex88 that looks like your flow is attempting to write to a text file that either doesnt exist or node-red doesnt have permission to write to.

The issue @zenofmud and @afelix discussed here are (I believe) an under-the-hood issue (that has been fixed) in node-red core & unrelated to your issue of a flow failing to update a text file.

However, I could be wrong 🙂

---

<div class="post-metadata">

**Author:** ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)\
**Post date:** [23 August 2020 12:59 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/8 "2020-08-23T12:59:08Z")

</div>

Don't have the option to:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/b/3/b3ffc4a556f078e37e93391d3ae95039dcc56a8c.png)

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [23 August 2020 13:02 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/9 "2020-08-23T13:02:32Z")

</div>

You cant update node-red itself from within node-red.

Re-do the original installation to upgrade.

---

<div class="post-metadata">

**Author:** ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)\
**Post date:** [23 August 2020 13:05 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/10 "2020-08-23T13:05:06Z")

</div>

Doh!!!

Of course.

---

<div class="post-metadata">

**Author:** ![alex88](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/alex88/32/55523_2.png) [@alex88](https://discourse.nodered.org/u/alex88)\
**Post date:** [23 August 2020 13:07 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/11 "2020-08-23T13:07:37Z")

</div>

> [@zenofmud](#):
>
> Try using NR 1.1.3

That fixed it. Thanks!

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [23 August 2020 13:28 UTC](https://discourse.nodered.org/t/error-enoent-no-such-file-or-directory-shows-on-log-when-opening-debug-in-new-window/29303/12 "2020-08-23T13:28:36Z")

</div>


