Node-RED loads the plugin files but its entrypoint isnt executed.
Repository to reproduce:
experiment
Steps to reproduce:
pnpm install
pnpm build:server:dev
install dist folder in your node-red
start node-red and verify server plugin files are loaded but its entrypoint function is never executed
Environment:
Node-RED version: 4.1.0 and 4.0.9
Node 18 and 22
Macos
What am I during wrong? Even when opening the editor I dont see the plugin's server entrypoint tunction being executed.
Opened an issue in github
opened 11:21PM - 11 Sep 25 UTC
needs-triage
### Current Behavior
Node-RED loads the plugin files but its entrypoint isn't e… xecuted.

<img width="701" height="407" alt="Image" src="https://github.com/user-attachments/assets/a6e0965a-6a12-4229-a2eb-f9fad8844bae" />



### Expected Behavior
Plugin's server entrypoint must run before nodes are loaded when its files are required by node-red, specially if node-red says the plugin is loaded and enabled
### Steps To Reproduce
0. Clone https://github.com/AllanOricil/node-red-nrg-plugin-tests
1. pnpm install
2. pnpm build:server:dev. If you open dist/package.json you will see that the plugin entrypoint is set under a node-red prop.
3. install dist folder in your node-red
4. start node-red and verify server plugin files are loaded but its entrypoint function is never executed
### Example flow
NA
### Environment
- Node-RED version: 4.1.0 and 4.0.9
- Node.js version: 22 and 18
- npm version: NA
- Platform/OS: nacos
- Browser: NA
I'm a bit confused as to how you are trying to do things. You still need an entry in the package.json don't you? In order to tell Node-RED that the plugin needs to be processed?
There is. The files are required by node-red. But the entrypoint is called.
This is the entrypoint being required by node-red
Here is the initial plugin being loaded without a problem
AllanOricil:
There is
I must be missing something:
Don't you need a node-red section?
Look at the dist. You must build it, and install the build
OK, dist isn't in the github repo so I can't see it.
Normally though, the package.json that node-red will acknowledge is in the root of the package, not in a folder. Could that be the issue?
I installed the dist folder.
OK, I don't think I can help without running your build which I can't do right now.
Continue in the github issue.