git push heroku master
中指定了Push rejected
, Python-3.4.3
命令会显示runtime.txt
。我更改了值,因为我在Windows 7系统上使用了python 3.4。
完整错误追溯
(denv) C:\Users\Saket\denv\musicalguru>git push heroku master
Counting objects: 7, done.
Compressing objects: 100% (4/4), done.
Writing objects: 100% (6/6), 488 bytes | 0 bytes/s, done.
Total 6 (delta 2), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Python app detected
remote: -----> Found runtime python-2.7.10, removing
remote: -----> Installing runtime (python-3.4.3)
remote: -----> Installing dependencies with pip
remote: Collecting beautifulsoup4==4.3.2 (from -r requirements.txt (line1))
remote: Downloading beautifulsoup4-4.3.2.tar.gz (143kB)
remote: Collecting dj-database-url==0.3.0 (from -r requirements.txt (line 2))
remote: Downloading dj_database_url-0.3.0-py2.py3-none-any.whl
remote: Collecting dj-static==0.0.6 (from -r requirements.txt (line 3))
remote: Downloading dj-static-0.0.6.tar.gz
remote: Collecting Django==1.8.2 (from -r requirements.txt (line 4))
remote: Downloading Django-1.8.2-py2.py3-none-any.whl (6.2MB)
remote: Collecting django-hvad==1.2.2 (from -r requirements.txt (line 5))
remote: Downloading django-hvad-1.2.2.tar.gz (99kB)
remote: Collecting django-libs==1.66.2 (from -r requirements.txt (line 6))
remote: Downloading django-libs-1.66.2.tar.gz (129kB)
remote: Collecting django-postgrespool==0.3.0 (from -r requirements.txt (line 7))
remote: Downloading django-postgrespool-0.3.0.tar.gz
remote: Collecting django-toolbelt==0.0.1 (from -r requirements.txt (line8))
remote: Downloading django-toolbelt-0.0.1.tar.gz
remote: Collecting factory-boy==2.5.2 (from -r requirements.txt (line 9))
remote: Downloading factory_boy-2.5.2-py2.py3-none-any.whl
remote: Collecting fudge==1.1.0 (from -r requirements.txt (line 10))
remote: Downloading fudge-1.1.0.tar.gz (86kB)
remote: Collecting gunicorn==19.3.0 (from -r requirements.txt (line 11))
remote: Downloading gunicorn-19.3.0-py2.py3-none-any.whl (110kB)
remote: Collecting Pillow==2.8.2 (from -r requirements.txt (line 12))
remote: Downloading Pillow-2.8.2.tar.gz (9.1MB)
remote: Collecting psycopg2==2.6.1 (from -r requirements.txt (line 13))
remote: Downloading psycopg2-2.6.1.tar.gz (371kB)
remote: Collecting requests==2.7.0 (from -r requirements.txt (line 14))
remote: Downloading requests-2.7.0-py2.py3-none-any.whl (470kB)
remote: Collecting South==1.0.2 (from -r requirements.txt (line 15))
remote: Downloading South-1.0.2.tar.gz (96kB)
remote: Collecting SQLAlchemy==1.0.5 (from -r requirements.txt (line 16))
remote: Downloading SQLAlchemy-1.0.5.tar.gz (4.6MB)
remote: Collecting static3==0.6.1 (from -r requirements.txt (line 17))
remote: Downloading static3-0.6.1.tar.gz
remote: Collecting wheel==0.24.0 (from -r requirements.txt (line 18))
remote: Downloading wheel-0.24.0-py2.py3-none-any.whl (63kB)
remote: Collecting whitenoise==2.0 (from -r requirements.txt (line 19))
remote: Downloading whitenoise-2.0-py2.py3-none-any.whl
remote: Collecting wsgiref==0.1.2 (from -r requirements.txt (line 20))
remote: Downloading wsgiref-0.1.2.zip
remote: Complete output from command python setup.py egg_info:
remote: Traceback (most recent call last):
remote: File "<string>", line 20, in <module>
remote: File "/tmp/pip-build-okgbhbhf/wsgiref/setup.py", line 5, in<module>
remote: import ez_setup
remote: File "/tmp/pip-build- okgbhbhf/wsgiref/ez_setup/__init__.py", line 170
remote: print "Setuptools version",version,"or greater has been installed."
remote: ^
remote: SyntaxError: Missing parentheses in call to 'print'
remote:
remote: ----------------------------------------
remote: Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-okgbhbhf/wsgiref
remote:
remote: ! Push rejected, failed to compile Python app
remote:
remote: Verifying deploy....
remote:
remote: ! Push rejected to musicalguru.
remote:
To https://git.heroku.com/musicalguru.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/musicalguru.git'
可能是什么问题?无法弄清楚。
答案 0 :(得分:3)
wsgiref
附带Python 3标准库,因此您无需再单独安装它。将其从您的需求文件中删除。