'gunicorn' is not recognized as an internal or external command with Heroku Local

Viewed 2472

I'm trying to run the command heroku local when following the section Push Local Changes in the tutorial: Heroku Python Tutorial

I'm getting the error:

[OKAY] Loaded ENV .env File as KEY=VALUE Format 18:51:47 web.1 | 'gunicorn' is not recognized as an internal or external command, 18:51:47 web.1 | operable program or batch file. [DONE] Killing all processes with signal SIGINT 18:51:47 web.1 Exited with exit code null

I tried searching online but I haven't found anything useful. Does someone have an idea how to solve this error?

EDIT: I have successfully implemented all the previous steps of the tutorial, and if I run CMD in the folder C:\python-getting-started and run the command pip list, the dependencies are:

Package         Version
--------------- ---------
asgiref         3.2.10
certifi         2020.6.20
chardet         3.0.4
dj-database-url 0.5.0
Django          3.0.8
django-heroku   0.3.1
gunicorn        20.0.4
idna            2.10
pip             20.2
psycopg2        2.8.5
pytz            2020.1
requests        2.24.0
setuptools      41.2.0
sqlparse        0.3.1
urllib3         1.25.10
whitenoise      5.1.0

Thanks

1 Answers

Looking at the former step Run app locally, We can see the following information:

If you’re on Microsoft Windows system, run this:

heroku local web -f Procfile.windows
...
Just like Heroku, heroku local examines the Procfile to determine what to run.

Meaning, Windows requires the -f Procfile.windows flag.
Please try running heroku local -f Procfile.windows.

Related