# Error in Node shown in Palette view; how to debug?

**URL:** <https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081>\
**Category:** Developing Nodes\
**Created:** [20 November 2018 19:09 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081 "2018-11-20T19:09:09Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![RaimondB](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/raimondb/32/3903_2.png) [@RaimondB](https://discourse.nodered.org/u/RaimondB)\
**Post date:** [20 November 2018 19:09 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/1 "2018-11-20T19:09:09Z")

</div>

Hi,

I'm am developing a new version of my node; however when I test it via the npm link procedure, it shows up in the Palette Manager, but with a strange error and I have no idea how to debug this.

Can anybody provide hints or tips?

![ErrorNodeRed](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/7/76ca60aad59de1a3e4ad6a6f772bb31b83a942f6.png)

Thanks,  
Raimond

---

<div class="post-metadata">

**Author:** ![hotNipi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/hotnipi/32/383_2.png) [@hotNipi](https://discourse.nodered.org/u/hotNipi)\
**Post date:** [20 November 2018 19:39 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/2 "2018-11-20T19:39:03Z")

</div>

Any error in browser console?

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [20 November 2018 19:42 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/3 "2018-11-20T19:42:39Z")

</div>

You'll need to look at the Node-RED log (not browser console) to see the details.

---

<div class="post-metadata">

**Author:** ![RaimondB](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/raimondb/32/3903_2.png) [@RaimondB](https://discourse.nodered.org/u/RaimondB)\
**Post date:** [20 November 2018 19:43 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/4 "2018-11-20T19:43:56Z")

</div>

No errors; I'm looking at the palette code to determine how node listed here are being validated. It seems that node-red itself finds the node invalid.

Strangely, it does work at my local installation on Windows, but it does not on my RPI. Both are node-red version 0.19.5

---

<div class="post-metadata">

**Author:** ![RaimondB](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/raimondb/32/3903_2.png) [@RaimondB](https://discourse.nodered.org/u/RaimondB)\
**Post date:** [20 November 2018 19:44 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/5 "2018-11-20T19:44:34Z")

</div>

The console log is also not showing any errors ☹

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [20 November 2018 19:49 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/6 "2018-11-20T19:49:27Z")

</div>

The Node-RED log _will_ have an entry relating to this node module... it'll be near the start when it first loads the nodes and before your flows are running.

---

<div class="post-metadata">

**Author:** ![RaimondB](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/raimondb/32/3903_2.png) [@RaimondB](https://discourse.nodered.org/u/RaimondB)\
**Post date:** [20 November 2018 19:53 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/7 "2018-11-20T19:53:17Z")

</div>

You are right 👍

This is the error, though I still don't get what it is related to..

> 20 Nov 20:50:47 - [warn] ------------------------------------------------------  
> 20 Nov 20:50:47 - [warn] [node-red-contrib-nefit-easy2/nefit-easy] Error: Cannot find module './lib'  
> 20 Nov 20:50:47 - [warn] ------------------------------------------------------

Also, this error does not occur when I test on windows

---

<div class="post-metadata">

**Author:** ![RaimondB](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/raimondb/32/3903_2.png) [@RaimondB](https://discourse.nodered.org/u/RaimondB)\
**Post date:** [21 November 2018 13:39 UTC](https://discourse.nodered.org/t/error-in-node-shown-in-palette-view-how-to-debug/5081/8 "2018-11-21T13:39:14Z")

</div>

I have a workaround for the issue: it was related to some subdependencies with inconsistent versions in de node\_modules. By cleaning out all modules and “npm link” again, the error went away.

Also when installing via the palette, the error does not occur.

So it seems to be a specfic RPi thing.
