Installation errors when setting up for custom node developement

Describe the problem/error/question

I am trying to develop a custom node. As such, I am following the youtube tutorial and the docs from n8n.
I have cloned the n8n-nodes-starter repo named as n8n-my-nodes into a windows directory.

I have installed n8n version 1.9.0 specifically to follow exactly the directives in the youtube tutorial (I have also tried with lts) like this:

npm install [email protected] -g

after:

npm list -g

this is the output:

C:\Users\aprestamo\AppData\Roaming\npm
+-- [email protected]
+-- [email protected]
`-- [email protected]

I tested n8n server and it works good.

Then I navigated into n8n-my-nodes and executed:

npm install

which outputed the following:

npm WARN ERESOLVE overriding peer dependency
npm WARN While resolving: [email protected]
npm WARN Found: [email protected]
npm WARN node_modules/n8n/node_modules/n8n-nodes-base
npm WARN   n8n-nodes-base@"1.9.3" from [email protected]
npm WARN   node_modules/n8n
npm WARN     n8n@"^1.9.0" from the root project
npm WARN
npm WARN Could not resolve dependency:
npm WARN peer n8n-nodes-base@"1.9.2" from [email protected]
npm WARN node_modules/n8n/node_modules/n8n-core
npm WARN   n8n-core@"1.9.1" from [email protected]
npm WARN   node_modules/n8n
npm WARN
npm WARN Conflicting peer dependency: [email protected]
npm WARN node_modules/n8n-nodes-base
npm WARN   peer n8n-nodes-base@"1.9.2" from [email protected]
npm WARN   node_modules/n8n/node_modules/n8n-core
npm WARN     n8n-core@"1.9.1" from [email protected]
npm WARN     node_modules/n8n
npm WARN deprecated [email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated @npmcli/[email protected]: This functionality has been moved to @npmcli/fs
npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-url#deprecated
npm WARN deprecated [email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated [email protected]: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated [email protected]: Please switch to @apidevtools/json-schema-ref-parser
npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-resolve#deprecated
npm WARN deprecated [email protected]: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies
npm WARN deprecated [email protected]: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated [email protected]: dommatrix is no longer maintained. Please use @thednp/dommatrix.
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
npm WARN deprecated @oclif/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

I then reinstalled with flag --legacy-peer-deps with no warnings other that the deprecated ones.

after this, I executed the following command insde n8n-my-nodes folder:
npm link

This outputed no errors, and 1 package added.
after executing:

npm list -g

it outputed

C:\Users\aprestamo\AppData\Roaming\npm
+-- [email protected] -> .\..\..\..\Documents\repos\n8n-my-nodes
+-- [email protected]
+-- [email protected]
`-- [email protected]

now i navigate to C:\Users\aprestamo\AppData\Roaming\npm\node_modules\n8n
and execute:

npm link n8n-my-nodes
this outputs some warnings related to deprecated

I start my n8n instance again with

n8n start

i reload editor and i cant see the example nodes.

i execute npm list (inside the n8n folder):
which outputed some packages. I will show a fragment of the output, where the n8n-my-nodes is displayed:

+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected] extraneous -> .\..\..\..\..\..\Documents\repos\n8n-my-nodes
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]

What is wrong?

node version:
v18.18.2
npm version:
10.2.0
n8n version installed with npm:
1.9.0

Hi @Adrian_Prestamo, welcome to the community!

I am sorry you are having trouble. Perhaps @marcus from our node engineering team can help with this one? Iirc he’s also developing on Windows.

Hello,
I just found another user with the exact same problem.

I’ve also tried doing the same in linux but had the exact same problem.

He opened a issue in the nodes-starter repo.
Here’s the link repo

Hey @Adrian_Prestamo,
instead of linking your node in C:\Users\aprestamo\AppData\Roaming\npm\node_modules\n8n you should be linking it in the ~/.n8n/custom/ directory. In your case this should be:

cd C:\Users\aprestamo\.n8n\custom
npm link n8n-my-nodes

If the custom folder does not exist just create one. Does that work for you?

1 Like

Hello, @marcus

Thank you for you time and answer.
I have tried as you said but it didnt work.
It took a while when I did the link command

it didnt output any errors other than the previous deprecated warnings.
It added a lot of packages (like 1.3k)
I then ran n8n start but the starter nodes are still not shown.

I will try now to do it in a clean xubuntu image.
I am also going to try and unisntall n8n npm package and install lts (i was using 1.9.0 trying to follow the video)

I will keep you updated.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.