我正在尝试将我的应用程序上传到heroku,但heroku/python
构建包没有构建我的应用程序并说它与它不兼容,我有一个Procfile
和一个requirements.txt
文件。所有必需的文件都已添加并提交,该应用程序在我的本地计算机上完美运行。
这是需求文件:
这是Proc文件:
这是输出:
$ git push heroku master
Enumerating objects: 197, done.
Counting objects: 100% (197/197), done.
Delta compression using up to 4 threads
Compressing objects: 100% (189/189), done.
Writing objects: 100% (197/197), 51.94 KiB | 2.16 MiB/s, done.
Total 197 (delta 93), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> App not compatible with buildpack: https://buildpack-registry.s3.amazonaws.com/buildpacks/heroku/python.tgz
remote: More info: https://devcenter.heroku.com/articles/buildpacks#detection-failure
remote:
remote: ! Push failed
remote: !
remote: ! ## Warning - The same version of this code has already been built: 644afa937ebb796a0ba0e2c8f3a459f4accbac36
remote: !
remote: ! We have detected that you have triggered a build from source code with version 644afa937ebb796a0ba0e2c8f3a459f4accbac36
remote: ! at least twice. One common cause of this behavior is attempting to deploy code from a different branch.
remote: !
remote: ! If you are developing on a branch and deploying via git you must run:
remote: !
remote: ! git push heroku <branchname>:main
remote: !
remote: ! This article goes into details on the behavior:
remote: ! https://devcenter.heroku.com/articles/duplicate-build-version
remote:
remote: Verifying deploy...
remote:
remote: ! Push rejected to botsenior.
remote:
该文件夹本身看起来像这样:
我已尽我所能来解决这个问题。我多次删除了heroku应用程序并再次创建了它,我尝试更改requirements.txt文件中的模块版本,但似乎没有任何效果。非常感谢您的帮助。
注意:我从一个源分支推送,该分支不是本地 git 存储库上的 master 分支,但我将其推送到 heroku 远程存储库上的 master 分支。我不知道这是否是一个问题,但我认为指定这一点很重要
繁星淼淼
相关分类