# SLS Deploy Error in Python: Error: spawn python3.8 ENOENT

**URL:** <https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958>\
**Category:** Serverless Framework\
**Tags:** aws\
**Created:** [March 31, 2022, 3:04pm UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958 "2022-03-31T15:04:20Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![pankaj-garg](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/pankaj-garg/32/6717_2.png) [@pankaj-garg](https://forum.serverless.com/u/pankaj-garg)\
**Post date:** [March 31, 2022, 3:04pm UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/1 "2022-03-31T15:04:20Z")

</div>

ubuntu@jumpboxAndawscli:/data/integrations$ sudo sls deploy --stage prod  
Serverless: Configuration warning at ‘provider’: unrecognized property ‘configfile’  
Serverless:  
Serverless: Learn more about configuration validation here:  
Serverless:  
Serverless: Using deployment bucket ‘prod-sls-deployments’  
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

---

<div class="post-metadata">

**Author:** ![MagicJF](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/magicjf/32/6762_2.png) [@MagicJF](https://forum.serverless.com/u/MagicJF)\
**Post date:** [April 20, 2022, 10:35am UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/2 "2022-04-20T10:35:50Z")

</div>

I do have the same problem :S  
Did you figure it out?

---

<div class="post-metadata">

**Author:** ![riga](https://avatars.discourse-cdn.com/v4/letter/r/8e8cbc/32.png) [@riga](https://forum.serverless.com/u/riga)\
**Post date:** [April 22, 2022, 11:06am UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/3 "2022-04-22T11:06:02Z")

</div>

Problem for me was than Python version installed in my Docker container was  
`FROM python:3.9-slim-buster`

but in serverless.yml provider referenced  
`runtime: python3.8`

changed container version to  
`FROM python:3.8-slim-buster`  
and happy thereafter (quite slow deployment though)

---

<div class="post-metadata">

**Author:** ![pankaj-garg](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/pankaj-garg/32/6717_2.png) [@pankaj-garg](https://forum.serverless.com/u/pankaj-garg)\
**Post date:** [April 22, 2022, 11:52am UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/4 "2022-04-22T11:52:09Z")

</div>

Problem for me was resolved when I changed the python version to 3.6

---

<div class="post-metadata">

**Author:** ![MagicJF](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/magicjf/32/6762_2.png) [@MagicJF](https://forum.serverless.com/u/MagicJF)\
**Post date:** [April 25, 2022, 4:35pm UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/5 "2022-04-25T16:35:02Z")

</div>

I also solved it, seems you can not use python 3.10 to run the plugin.  
I recorded the steps in case I need to review on the future, here they are in case someone is stuck: [Setup Plugin Serverless Python Requirements - YouTube](https://youtu.be/giDgwfA2_aw)

---

<div class="post-metadata">

**Author:** ![morgan-young1](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.serverless.com/morgan-young1/32/6852_2.png) [@morgan-young1](https://forum.serverless.com/u/morgan-young1)\
**Post date:** [May 19, 2022, 10:30am UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/6 "2022-05-19T10:30:59Z")

</div>

I also got this and resolved in a similar way. It’s a real shame we can’t use python 3.10 to run the plugin even if the runtime of the function itself is a supported version like 3.8 etc.

After I resolved this I then spent ages grappling with this for ages as well! [serverless deploy -\> Exited with code 1 · Issue #663 · serverless/serverless-python-requirements · GitHub](https://github.com/serverless/serverless-python-requirements/issues/663)

I think there is a problem with the Docker image for python 3.8. I got it working by setting dockerizePip to false

---

<div class="post-metadata">

**Author:** ![palak231](https://avatars.discourse-cdn.com/v4/letter/p/b38774/32.png) [@palak231](https://forum.serverless.com/u/palak231)\
**Post date:** [June 10, 2022, 11:20am UTC](https://forum.serverless.com/t/sls-deploy-error-in-python-error-spawn-python3-8-enoent/16958/7 "2022-06-10T11:20:39Z")

</div>

Hi @MagicJF I am also expecting such video for perfect solution.  
Thanks
