Solve Python Error – H14 error in heroku – “no web processes running”

Solve Python Error – H14 error in heroku – “no web processes running” is a Python WebDriver error which occurs in heroku when no web dyno is configured.

In this article I am going to try and solve the error while I try to explain why the error is actually popping up, we will also introduce some solutions that have worked for other devs and see if those solutions can solve the error in your particular situation.

Explaining Python Error – H14 error in heroku – “no web processes running”

The error happens in heroku when no web dyno is configured.

The log/meessage will look like something like this.

                                                                       #
at=error code=H14 desc="No web processes running" method=GET path="/" host=meetcapstone.herokuapp.com request_id=df88efb5-a81a-4ac0-86dc-4e03d71266bb fwd="81.218.117.137" dyno= connect= service= status=503 bytes=
heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/favicon.ico" host=meetcapstone.herokuapp.com request_id=21cea981-36b0-4410-891f-548bbc29f0ee fwd="81.218.117.137" dyno= connect= service= status=503 bytes=
                                                                       #

Bellow we will take care of the error using multiple possible solutions according to your needs.

Solution 1 : remove and redeploy buildpacks to heroku

The first solution is to take care of the buildpacks in heroku.

First, remove the buildpacks.

Empty the buildpacks.

Finally, you should commit and redeploy to heroku

Use the command bellow.

                                                                       #
heroku buildpacks:clear
heroku buildpacks:add --index heroku/python
                                                                       #

If this did not work, follow the solution bellow.

Solution 2 : run a web dyno

The first reason for this error is that heroku needs a web dyno, which you haven’t installed.

Install a web dyno by running the command bellow.

                                                                       #
heroku ps:scale web=1
                                                                       #

I hope this solution works for you.

                                                                       #
at=error code=H14 desc="No web processes running" method=GET path="/" host=meetcapstone.herokuapp.com request_id=df88efb5-a81a-4ac0-86dc-4e03d71266bb fwd="81.218.117.137" dyno= connect= service= status=503 bytes=
heroku[router]: at=error code=H14 desc="No web processes running" method=GET path="/favicon.ico" host=meetcapstone.herokuapp.com request_id=21cea981-36b0-4410-891f-548bbc29f0ee fwd="81.218.117.137" dyno= connect= service= status=503 bytes=
                                                                       #

The error message above, should be gone by now.

If this article has been useful for your particular case, consider donating to our Kofi account, there is a red button at the top of this page.

Summing-up

I hope my article was helpful in solving this error, errors are part of our journey of coding with Python, keep learning, keep coding and cheers. If you want to learn more about Python, please check out the Python Documentation : https://docs.python.org/3/