heroku-找不到该进程类型(web)

heroku-找不到该进程类型(web),heroku,Heroku,我正在学习教程 但是我弄错了 Scaling dynos... ! ▸ Couldn't find that process type (web). 当做 heroku ps:scale web=1 我遵循了解决方案 通过删除buildpack并使用heroku buildpacks:set heroku/python 但错误仍然存在 对于构建包: heroku buildpacks === teaching-system Buildpack URL heroku/python 这

我正在学习教程

但是我弄错了

Scaling dynos... !
 ▸    Couldn't find that process type (web).
当做

heroku ps:scale web=1
我遵循了解决方案

通过删除buildpack并使用heroku buildpacks:set heroku/python

但错误仍然存在

对于构建包:

heroku buildpacks
=== teaching-system Buildpack URL
heroku/python
这似乎是正确的


有什么问题吗?

请确保您的Procfile与Pipfile和Pipfile.lock文件位于同一目录中

我正在使用django,在我的Procfile中:

程序文件 web:gunicorn.wsgi-日志文件-
如果尚未安装gunicorn,请安装。我也有同样的错误,花了很长时间试图解决它,所以我希望这能有所帮助。语法将根据您使用的框架和语言而变化,但想法应该类似。

如果您在推送到Heroku master后修改了Procfile或重命名了它,则可能会发生这种情况。如果是这样,您可以尝试通过重建索引使其工作

在我的情况下,这起了作用:

删除缓存文件只有路径从索引中删除,而不是真正的文件

gitrm-r-cached

将所有文件添加到索引中

git添加

承诺

git commit-m有望修复错误

再次运行其余的heroku命令


为我工作!希望对您有用。

几周后,我在另一个Flask项目中解决了这个问题


这是因为失去了library:gunicorn在当前虚拟环境中

在Django,我解决了创建下一个文件的问题:

--------------------------------------------
**Procfile.windows** :
web: python manage.py runserver 0.0.0.0:5000
-------------------------------------------
**requirements.txt** :
django
gunicorn
django-heroku
------------------------------------------
**runtime.txt** :
python-3.7.7
-------------------------------------------------------
**Procfile** :
web: gunicorn <name of my main folder app>.wsgi --log-file -
----------------------
**.env** :
TIMES=2
----------------------
在完成对本地存储库的提交后,步骤如下:

* heroku登录 赫罗库创造 git提交-m gogogo heroku git推送heroku主机 heroku ps:scale web=1 赫罗库公开赛


*这就是我在Django中克服这个错误所做的。在10号窗口

添加Procfile-在拥有git的同一文件夹中,manage.py
欢迎来到堆栈溢出。因为他们付出的努力和价值都很低。它们也会受到链接腐朽的影响,当链接在将来断开时,它们往往会变得毫无用处。请编辑您的答案,并将要点直接包含在您的问题中。看。这就是我要找的8小时。这个问题发生是因为我没有安装gunicorn。一年前我问了这个问题,最后通过安装gunicorn模块解决了这个问题。mac和win10都能工作。
Procfile
-------------------------------
web: gunicorn <django-root-name(containing wsgi)>.wsgi --log-file -
Procfile.windows
------------------------------------------
web: python manage.py runserver 0.0.0.0:5000