Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/heroku/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Django 赫罗库可以';我没有发现python是必要的_Django_Heroku - Fatal编程技术网

Django 赫罗库可以';我没有发现python是必要的

Django 赫罗库可以';我没有发现python是必要的,django,heroku,Django,Heroku,我有一个与Django的两个勺子中描述的结构相似的项目 即: 1.photoarchive_项目是存储库根目录(即.git所在的位置)。 2.该项目本身就是photoarchive。 3.配置文件对于不同的现实是不同的 回溯和其他信息如下 文件runtime.txt位于.git目录旁边。它就在git初始化的目录中 问题是:它甚至不能确定应该应用python。你能在这里踢我一脚吗 .git/config [core] repositoryformatversion = 0 file

我有一个与Django的两个勺子中描述的结构相似的项目

即: 1.photoarchive_项目是存储库根目录(即.git所在的位置)。 2.该项目本身就是photoarchive。 3.配置文件对于不同的现实是不同的

回溯和其他信息如下

文件runtime.txt位于.git目录旁边。它就在git初始化的目录中

问题是:它甚至不能确定应该应用python。你能在这里踢我一脚吗

.git/config

[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
[remote "origin"]
    url = ssh://git@bitbucket.org/Kifsif/photoarchive.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
    remote = origin
    merge = refs/heads/master
[remote "heroku"]
    url = https://git.heroku.com/powerful-plains-97572.git
    fetch = +refs/heads/*:refs/remotes/heroku/*
回溯

(photoarchive) michael@ThinkPad:~/workspace/photoarchive_project$ git push 

    heroku master
    Counting objects: 3909, done.
    Delta compression using up to 4 threads.
    Compressing objects: 100% (3617/3617), done.
    Writing objects: 100% (3909/3909), 686.44 KiB | 0 bytes/s, done.
    Total 3909 (delta 2260), reused 0 (delta 0)
    remote: Compressing source files... done.
    remote: Building source:
    remote: 
    remote:  !     No default language could be detected for this app.
    remote:             HINT: This occurs when Heroku cannot detect the buildpack to use for this application automatically.
    remote:             See https://devcenter.heroku.com/articles/buildpacks
    remote: 
    remote:  !     Push failed
    remote: Verifying deploy...
    remote: 
    remote: !   Push rejected to powerful-plains-97572.
    remote: 
    To https://git.heroku.com/powerful-plains-97572.git
     ! [remote rejected] master -> master (pre-receive hook declined)
    error: failed to push some refs to 'https://git.heroku.com/powerful-plains-97572.git'

(photoarchive) michael@ThinkPad:~/workspace/photoarchive_project$ tree
.
├── docs
├── media
├── photoarchive
│   ├── config
│   │   ├── settings
│   │   │   ├── base.py
│   │   │   ├── constants.py
│   │   │   ├── heroku.py
│   │   │   ├── __init__.py
│   │   │   ├── local.py
│   │   │   └── production.py
│   └── manage.py
├── .git
├── .gitignore
├── Procfile
└── runtime.txt
runtime.txt

python-3.6.1

I

您需要在项目文件夹的根目录中定义一个
requirements.txt
。此文件应包含所有项目依赖项的列表

您可以通过运行以下命令在本地开发计算机上生成此文件:

$ pip freeze > requirements.txt
然后将其检查到版本控制中,并将其推送到Heroku

Heroku查找此文件以确定您的应用程序实际上是Python应用程序=)