Mithil Bhoras
Mithil Bhoras

Reputation: 904

Heroku and Django: No default language could be detected for this app

I have followed the instructions given under a tutorial (Link here). I have even included the runtime.txt file with the proper version of Python. I have searched everywhere but no solution seems to work. My GitHub project link for reference:

https://github.com/MithilRocks/chakri

The error message:

PS C:\Users\Mithil Bhoras\Documents\GitHub\chakri\chakri> git push heroku master
Counting objects: 90, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (80/80), done.
Writing objects: 100% (90/90), 8.78 MiB | 234.00 KiB/s, done.
Total 90 (delta 26), 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 chakrilevels.
remote:
To https://git.heroku.com/chakrilevels.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/chakrilevels.git'

Upvotes: 2

Views: 5754

Answers (2)

Bassam Msmar
Bassam Msmar

Reputation: 41

you can write requirements.txt by small litter to "r" not Requirements.txt if you do not have requirements.txt file you should make this file in "cmd" can write this line

freeze > requirements.txt

Upvotes: 0

Ioanna
Ioanna

Reputation: 1377

For future readers, the same solution as @hansTheFranz's comment, but from the command line:

  • At app creation: heroku create --buildpack heroku/python app_name

  • For an existing app: heroku buildpacks:set heroku/python

Also, the official Heroku Buildpack: Python documentation could help.

Upvotes: 2

Related Questions