Hi, I am creating a flask app web service with the free plan but I am getting the [CRITICAL] WORKER TIMEOUT error whenever I am making a request to the endpoint.

I created a docker container to check the resources used, and they were 0.01% of CPU and 267MB of RAM. This means that resources probably are not the problem.

The flask app serves a cnn module, so I am using pytoch and opencv. I don’t if this affects in anyway the deploy.

Hi there,

This error means your service is hitting a Gunicorn worker timeout, which defaults to 30 seconds. You can try and increase this by using the -t / --timeout option when you start Gunicorn. However, I wouldn’t recommend doing this as a long-term solution.

There can be several reasons for this, but it usually all boils down to your request getting stuck within your service. Typically, calls to 3rd party API, database connections or queries, etc., which have a longer than 30-second timeout, will cause issues if they get stuck.


Render Support, UTC+10 :australia:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.