# Unable to test a custom node locally (npm link)

**URL:** <https://discourse.nodered.org/t/unable-to-test-a-custom-node-locally-npm-link/7403>\
**Category:** General\
**Created:** [30 January 2019 18:29 UTC](https://discourse.nodered.org/t/unable-to-test-a-custom-node-locally-npm-link/7403 "2019-01-30T18:29:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cesar.Cervantes](https://avatars.discourse-cdn.com/v4/letter/c/e68b1a/32.png) [@Cesar.Cervantes](https://discourse.nodered.org/u/Cesar.Cervantes)\
**Post date:** [30 January 2019 18:29 UTC](https://discourse.nodered.org/t/unable-to-test-a-custom-node-locally-npm-link/7403/1 "2019-01-30T18:29:13Z")

</div>

Hi,

Environment:  
-Node 8.12.0  
-npm 6.4.1  
Win 10

I created a custom node following the template from the " **Creating your first node**" page.

It can be installed just fine, but I'm also trying to use the " **npm link**" command as decribed here: [Packaging : Node-RED](https://nodered.org/docs/creating-nodes/packaging) in the section " **Testing a node module locally**", this is the command I'm using:

> npm link \<path\_to\_node\_folder\>

It fails with the following error:

```
npm ERR! path C:\node-v8.12.0-win-x64\node_modules\TestNode\package.json
npm ERR! code ELOOP
npm ERR! errno -4067
npm ERR! syscall open
npm ERR! ELOOP: too many symbolic links encountered, open 'C:\node-v8.12.0-win-x64\node_modules\TestNode\package.json'

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\User1\AppData\Roaming\npm-cache\_logs\2019-01-30T18_01_16_133Z-debug.log

```

This is the full log: [http://oneclickpaste.com/1374/](http://oneclickpaste.com/1374/)

Has anyone seen this problem before?

---

<div class="post-metadata">

**Author:** ![cinhcet](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cinhcet/32/438_2.png) [@cinhcet](https://discourse.nodered.org/u/cinhcet)\
**Post date:** [30 January 2019 18:39 UTC](https://discourse.nodered.org/t/unable-to-test-a-custom-node-locally-npm-link/7403/2 "2019-01-30T18:39:37Z")

</div>

Although this is not an answer to your question, I recommend not using npm link. Just use npm install FolderName, this will also create a symlink to your local node and does not require admin rights like npm link.  
Of course FolderName should include the path to the package.

---

<div class="post-metadata">

**Author:** ![Cesar.Cervantes](https://avatars.discourse-cdn.com/v4/letter/c/e68b1a/32.png) [@Cesar.Cervantes](https://discourse.nodered.org/u/Cesar.Cervantes)\
**Post date:** [30 January 2019 19:56 UTC](https://discourse.nodered.org/t/unable-to-test-a-custom-node-locally-npm-link/7403/3 "2019-01-30T19:56:59Z")

</div>

Yes, it includes the path to the package
