My netlify function timeout in production but not in local environment

As I said, above it works in few secondes in local environment.
Can you give me your gitlab account please, I will add you to the project

May be it’s a difference between node version ? Which version is used at netlify ?

Currently it is Node v16. This support article gives you more details on our build environment: [Support Guide] Debugging Netlify site builds

It works like a charm in local. I always got problems using external library after deploying on netlify.

Can you give me a gitlab account or other way to resolve my problem please…


I find the solution. My mongodb account used to allow only the IP address of my local env.
I allow all IP for the moment. Can you provide IP Adresses range of netlify please ?

Glad to hear this is working for you. Unfortunately we cannot provide IP addresses.