Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting Serverless Error spawn python3.8 ENOENT in sls deploy for python requirements

Doing a serverless deployment using sls deploy and getting error "spawn python3.8 ENOENT"

ubuntu@jumpboxAndawscli:$ sudo sls deploy --stage prod
Serverless: Configuration warning at ‘provider’: unrecognized property ‘configfile’
Serverless:
Serverless: Learn more about configuration validation here:
Serverless:
Serverless: Updated deployment bucket public access block
Serverless: [serverless-package-external] is complete
Serverless: Generated requirements from /data/integrations/requirements.txt in /data/integrations/.serverless/requirements.txt…
Serverless: Installing requirements from /home/ubuntu/.cache/serverless-python-requirements/c83840509c18324c044b580033bb40d7104080235af12a1d9e3d118cf0675070_x86_64_slspyc/requirements.txt …
Serverless: Using download cache directory /home/ubuntu/.cache/serverless-python-requirements/downloadCacheslspyc

Error ---------------------------------------------------

Error: spawn python3.8 ENOENT
at Process.ChildProcess._handle.onexit (internal/child_process.js:268:19)
at onErrorNT (internal/child_process.js:470:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21)

 For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.
Your Environment Information ---------------------------
Operating System: linux
Node Version: 12.22.1
Framework Version: 2.72.2
Plugin Version: 5.5.4
SDK Version: 4.3.1
Components Version: 3.18.2
like image 446
Pankaj Garg Avatar asked May 21 '26 01:05

Pankaj Garg


1 Answers

Your local available python (current PATH) version MUST be the same version configured in your serverless.yml provider runtime value.

like image 194
alphaadidas Avatar answered May 23 '26 15:05

alphaadidas



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!