我在项目的外部目录中。当我尝试运行python manage.py runserver
时,它能够正常工作,但是如果我尝试部署我的代码并执行heroku run python manage.py migrate
,它会显示以下错误 -
(cenv) C:\Users\Machine\cenv\myproject>heroku run python manage.py migrate
Running `python manage.py migrate` attached to terminal... up, run.6848
python: can't open file 'manage.py': [Errno 2] No such file or directory
但是,当我输入
DIR
时,它显示manage.py
与同一目录下。 <DIR> .
<DIR> ..
59 .gitignore
<DIR> 2015
<DIR> feature
254 manage.py
<DIR> media
<DIR> myproject
43 Procfile
355 requirements.txt
12 runtime.txt
723 bytes
12,963,143,680 bytes free
(cenv) C:\Users\Machine\cenv\myproject>heroku run ls -al
Running `ls` attached to terminal... failed
! App not found
(cenv) C:\Users\Machine\cenv\myproject>heroku run pwd
Running `pwd` attached to terminal... up, run.3539
/app