Spawn python3 ENOENT when running a python script in nextjs api

Hi, @Jerenyaoyelu. The function you deploy is running in AWS Lambda. At this time, Netlify Functions support three different language runtimes as documented here:

Quoting that page:

Currently, you can deploy functions built with TypeScript, JavaScript, and Go.

On your local system, you have an entire operating system and all language runtimes installed. Based on your post that obviously included both Node.js and Python.

However, once the function is deployed, Python is no longer available. So, when the Node.js script tries to invoke a Python script, you get the error message from Node.js saying that python3 doesn’t exist. It is expected that python3 doesn’t exist for the deployed function as that language runtime isn’t supported at this time.

If there are other questions about this, please let us know.