Describe the problem/error/question
Recently there is a new linting rule: Require webhook trigger nodes to implement the complete webhookMethods lifecycle (checkExists, create, delete).
Per my understanding it is for webhooks that will register or unregister endpoints in external systems, for example the WebflowTrigger.
However the node I am building has no such endpoint to talk with and the webhook URL is configured manually in the external system’s setting page.
My question is that, while I can just write dummy checkExists (and its friends) to pass the linting will this bring negative impacts to the community node verification? Or do I need to make a statement saying that the webhook URL is configured manually in external systems so I am not able to register/unregister with the external system?
Information on your n8n setup
Not specific to n8n setup but @n8n/node-cli. I use latest stable node-cli 0.37.4
Hi @Victor_Tseng
Stubbing checkExists, create, and delete with dummies is the wrong fix, it adds dead code that misrepresents the node and reviewers can flag it during verification. The webhook URL is configured manually here and there is nothing to register or unregister, so disable the rule on the node file with a reason, which doubles as the statement you were going to add
/* eslint-disable @n8n/community-nodes/webhook-lifecycle-complete -- webhook URL is
configured manually in the external system, nothing to register or unregister */
If you think the rule shouldn’t fire for manually configured webhooks at all, report it in the n8n repo so they can scope it.
Hi @Anshul_Namdev,
Thanks for the clarification. That makes sense.
I was initially trying to avoid disabling the rule because I interpreted the must requirement as meaning the lifecycle methods should always be present for webhook-based triggers. And adding stub methods would indeed create misleading code.
I’ll use the inline eslint disable with an explanation as suggested, and I’ll also open an issue so that the n8n team can consider scoping it.