一切正常,除了1页投掷500(内部服务器错误)。 这里是完整的heroku日志:
(venv)MacBook-Pro:django_course_hw1 devs$ heroku logs
2016-08-24T18:45:51.974133+00:00 heroku[router]: at=info method=GET path="/static/img/git.d3c6f2d124dc.png" host=jsayapina.herokuapp.com request_id=c8a8155c-84d8-4a7d-9974-5be68648fb23 fwd="109.67.198.77" dyno=web.1 connect=0ms service=4ms status=200 bytes=73044
2016-08-24T18:45:52.974193+00:00 heroku[router]: at=info method=GET path="/static/img/favicon.1a6bc2acd77e.ico" host=jsayapina.herokuapp.com request_id=6f698576-fe73-42da-9d25-e38a212d2b8a fwd="109.67.198.77" dyno=web.1 connect=0ms service=1ms status=200 bytes=12986
2016-08-24T18:45:54.301083+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=91c57705-44a7-4431-836a-663345b96fbc fwd="109.67.198.77" dyno=web.1 connect=0ms service=34ms status=200 bytes=3696
2016-08-24T18:45:58.821817+00:00 heroku[router]: at=info method=GET path="/edu/" host=jsayapina.herokuapp.com request_id=af6854c4-9965-4694-9c91-3d6ccb33441f fwd="109.67.198.77" dyno=web.1 connect=0ms service=68ms status=200 bytes=10780
2016-08-24T18:46:01.117176+00:00 heroku[router]: at=info method=GET path="/exp/" host=jsayapina.herokuapp.com request_id=f77916a6-e7d7-4826-99b6-b9aefa95bf57 fwd="109.67.198.77" dyno=web.1 connect=0ms service=59ms status=200 bytes=10162
2016-08-24T18:46:03.572259+00:00 heroku[router]: at=info method=GET path="/contacts/" host=jsayapina.herokuapp.com request_id=339866c2-49e5-495d-a7ee-b2b5fcbb4495 fwd="109.67.198.77" dyno=web.1 connect=0ms service=6ms status=200 bytes=4990
2016-08-24T18:46:03.787412+00:00 heroku[router]: at=info method=GET path="/static/img/pdf.png" host=jsayapina.herokuapp.com request_id=b5ed9fd0-d810-4491-a51d-26f9cc4c78b2 fwd="109.67.198.77" dyno=web.1 connect=0ms service=1ms status=200 bytes=706
2016-08-24T18:46:55.250110+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=7b34e9b7-3e1d-4f3d-af63-686c931024c1 fwd="109.67.198.77" dyno=web.1 connect=0ms service=5ms status=200 bytes=3696
2016-08-24T18:46:58.755100+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=2fdc95d1-696a-4ca8-8922-09c901f3ef36 fwd="109.67.198.77" dyno=web.1 connect=0ms service=526ms status=500 bytes=3867
2016-08-24T18:47:10.329097+00:00 heroku[run.9396]: State changed from up to complete
2016-08-24T18:47:10.317573+00:00 heroku[run.9396]: Process exited with status 1
2016-08-24T19:14:56.439608+00:00 heroku[slug-compiler]: Slug compilation started
2016-08-24T19:14:56.439617+00:00 heroku[slug-compiler]: Slug compilation finished
2016-08-24T19:14:56.253749+00:00 heroku[api]: Deploy 74a47ca by julia.sayapina@me.com
2016-08-24T19:14:56.253855+00:00 heroku[api]: Release v37 created by julia.sayapina@me.com
2016-08-24T19:14:56.909546+00:00 heroku[web.1]: Restarting
2016-08-24T19:14:56.910232+00:00 heroku[web.1]: State changed from up to starting
2016-08-24T19:14:59.678375+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2016-08-24T19:15:00.577181+00:00 app[web.1]: [2016-08-24 19:15:00 +0000] [7] [INFO] Worker exiting (pid: 7)
2016-08-24T19:15:00.577199+00:00 app[web.1]: [2016-08-24 19:15:00 +0000] [3] [INFO] Handling signal: term
2016-08-24T19:15:00.780927+00:00 app[web.1]: [2016-08-24 19:15:00 +0000] [3] [INFO] Shutting down: Master
2016-08-24T19:15:00.574178+00:00 app[web.1]: [2016-08-24 19:15:00 +0000] [9] [INFO] Worker exiting (pid: 9)
2016-08-24T19:15:01.003545+00:00 heroku[web.1]: Process exited with status 0
2016-08-24T19:15:03.156662+00:00 heroku[web.1]: Starting process with command `gunicorn portfolio.wsgi`
2016-08-24T19:15:05.879698+00:00 app[web.1]: [2016-08-24 19:15:05 +0000] [7] [INFO] Booting worker with pid: 7
2016-08-24T19:15:05.875132+00:00 app[web.1]: [2016-08-24 19:15:05 +0000] [3] [INFO] Listening at: http://0.0.0.0:8112 (3)
2016-08-24T19:15:05.875301+00:00 app[web.1]: [2016-08-24 19:15:05 +0000] [3] [INFO] Using worker: sync
2016-08-24T19:15:05.874284+00:00 app[web.1]: [2016-08-24 19:15:05 +0000] [3] [INFO] Starting gunicorn 19.6.0
2016-08-24T19:15:05.906503+00:00 app[web.1]: [2016-08-24 19:15:05 +0000] [8] [INFO] Booting worker with pid: 8
2016-08-24T19:15:06.917846+00:00 heroku[web.1]: State changed from starting to up
2016-08-24T19:18:30.145261+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=2d80bf31-cdf3-4c85-bf92-ce9018096516 fwd="109.67.198.77" dyno=web.1 connect=0ms service=59ms status=200 bytes=3696
2016-08-24T19:18:35.333690+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=f8dca765-ea65-4263-a20d-3857feecb369 fwd="109.67.198.77" dyno=web.1 connect=0ms service=786ms status=500 bytes=3867
2016-08-24T19:23:31.721476+00:00 heroku[router]: at=info method=GET path="/static/js/script.d5ecb4c1ee49.js" host=jsayapina.herokuapp.com request_id=b5acf6be-c5de-4b46-837b-a4e3e14e8d4f fwd="109.67.198.77" dyno=web.1 connect=0ms service=5ms status=200 bytes=563
2016-08-24T19:23:31.430845+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=bdc8235e-b33e-4ca4-b618-4c2db581f5aa fwd="109.67.198.77" dyno=web.1 connect=0ms service=475ms status=500 bytes=3867
2016-08-24T19:23:31.707452+00:00 heroku[router]: at=info method=GET path="/static/styles/style.922a03ea63af.css" host=jsayapina.herokuapp.com request_id=54cd0650-c471-4dbc-a4e6-a2c96f2d6b5c fwd="109.67.198.77" dyno=web.1 connect=0ms service=2ms status=200 bytes=2558
2016-08-24T19:23:31.699536+00:00 heroku[router]: at=info method=GET path="/static/img/logo.5c2c14584915.png" host=jsayapina.herokuapp.com request_id=2b92dbcf-1713-4210-9167-2a7f561dbfe4 fwd="109.67.198.77" dyno=web.1 connect=0ms service=2ms status=200 bytes=914
2016-08-24T19:23:32.858574+00:00 heroku[router]: at=info method=GET path="/static/img/supernova.a6060279447b.png" host=jsayapina.herokuapp.com request_id=3581616f-bedf-462f-887a-fc532cec2d22 fwd="109.67.198.77" dyno=web.1 connect=0ms service=8ms status=200 bytes=163298
2016-08-24T19:23:32.861984+00:00 heroku[router]: at=info method=GET path="/static/img/git.d3c6f2d124dc.png" host=jsayapina.herokuapp.com request_id=13644aa9-7492-49bf-bcee-641435ec672f fwd="109.67.198.77" dyno=web.1 connect=0ms service=9ms status=200 bytes=73044
2016-08-24T19:23:32.890841+00:00 heroku[router]: at=info method=GET path="/static/img/map.85bd42badf89.jpg" host=jsayapina.herokuapp.com request_id=a970b42f-4dab-449e-a6d6-5056e629927e fwd="109.67.198.77" dyno=web.1 connect=0ms service=8ms status=200 bytes=116505
2016-08-24T19:23:33.879719+00:00 heroku[router]: at=info method=GET path="/static/img/favicon.1a6bc2acd77e.ico" host=jsayapina.herokuapp.com request_id=3ef24639-a4ca-4dc9-b595-14d22b4de722 fwd="109.67.198.77" dyno=web.1 connect=1ms service=3ms status=200 bytes=12986
2016-08-24T19:29:32.654919+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=e232d5ad-203f-46e5-87eb-c1d485eb0dc0 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=10ms status=200 bytes=3696
2016-08-24T19:29:32.696405+00:00 heroku[router]: at=info method=GET path="/static/img/logo.5c2c14584915.png" host=jsayapina.herokuapp.com request_id=2ecee2f4-e1e6-4add-8e20-99233bfe9f15 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=0ms service=2ms status=200 bytes=914
2016-08-24T19:29:32.659605+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=600ec0ae-dc2b-432a-a4e7-a649c76bdc28 fwd="8.28.16.254" dyno=web.1 connect=1ms service=9ms status=200 bytes=3696
2016-08-24T19:29:32.903434+00:00 heroku[router]: at=info method=GET path="/static/img/map.85bd42badf89.jpg" host=jsayapina.herokuapp.com request_id=8c24aca3-9f84-470d-8825-6a8dfed68c08 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=14ms status=200 bytes=116505
2016-08-24T19:29:32.708920+00:00 heroku[router]: at=info method=GET path="/static/img/favicon.1a6bc2acd77e.ico" host=jsayapina.herokuapp.com request_id=dd964aeb-46d1-4115-bdae-bf6200484a46 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=0ms service=15ms status=200 bytes=166715
2016-08-24T19:29:32.683546+00:00 heroku[router]: at=info method=GET path="/static/js/script.d5ecb4c1ee49.js" host=jsayapina.herokuapp.com request_id=f889627b-6fc7-4b43-a82c-95f2735c9dd4 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=1ms service=9ms status=200 bytes=1262
2016-08-24T19:29:32.741331+00:00 heroku[router]: at=info method=GET path="/static/img/avatar.6d999f0632fd.png" host=jsayapina.herokuapp.com request_id=a3778e6f-880f-4ae3-95d7-1a9bb0269fe0 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=0ms service=34ms status=200 bytes=1110581
2016-08-24T19:29:32.687459+00:00 heroku[router]: at=info method=GET path="/static/styles/style.922a03ea63af.css" host=jsayapina.herokuapp.com request_id=ff498167-9ed9-481a-9a20-169b1ed09c70 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=1ms service=7ms status=200 bytes=10924
2016-08-24T19:29:32.692811+00:00 heroku[router]: at=info method=GET path="/static/img/git.d3c6f2d124dc.png" host=jsayapina.herokuapp.com request_id=c7044129-2a57-49db-9d97-f55016e238a5 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=0ms service=18ms status=200 bytes=73044
2016-08-24T19:29:40.113191+00:00 heroku[router]: at=info method=GET path="/port" host=jsayapina.herokuapp.com request_id=47ae8611-861e-487a-b5e9-8208024be36e fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=4ms status=301 bytes=235
2016-08-24T19:29:40.375888+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=8340a992-d58f-449d-b5d8-9ae1821cf885 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=1ms service=90ms status=500 bytes=3867
2016-08-24T19:29:40.139274+00:00 heroku[router]: at=info method=GET path="/port" host=jsayapina.herokuapp.com request_id=58744460-b0f9-4b43-a3cf-5b9ce060054f fwd="8.28.16.254" dyno=web.1 connect=1ms service=4ms status=301 bytes=235
2016-08-24T19:29:40.411719+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=5f4347e1-c0ce-4d11-b269-e5771bee55e9 fwd="8.28.16.254" dyno=web.1 connect=1ms service=268ms status=500 bytes=3867
2016-08-24T19:29:40.275568+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=3dba8107-b0e9-46dc-91c4-8ba2fb611d59 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=0ms service=138ms status=500 bytes=3867
2016-08-24T19:29:40.381783+00:00 heroku[router]: at=info method=GET path="/static/img/supernova.a6060279447b.png" host=jsayapina.herokuapp.com request_id=792e77cf-7427-4111-a407-04edd6a50962 fwd="127.0.0.1,147.85.186.6" dyno=web.1 connect=1ms service=85ms status=200 bytes=163298
2016-08-24T19:29:48.691988+00:00 heroku[router]: at=info method=GET path="/static/img/logo.5c2c14584915.png" host=jsayapina.herokuapp.com request_id=08710fa5-3036-4202-964d-e3fd00def642 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=4ms status=304 bytes=152
2016-08-24T19:29:48.617574+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=fde752ed-bec0-47d4-9790-80563ca785cb fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=83ms status=500 bytes=3867
2016-08-24T19:29:48.755270+00:00 heroku[router]: at=info method=GET path="/static/img/supernova.a6060279447b.png" host=jsayapina.herokuapp.com request_id=55f73b04-004c-4777-9aa0-10fea12e3f2e fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=1ms service=16ms status=304 bytes=152
2016-08-24T19:29:48.775195+00:00 heroku[router]: at=info method=GET path="/static/js/script.d5ecb4c1ee49.js" host=jsayapina.herokuapp.com request_id=d5f76d02-0ea4-48bd-a3e8-ec766701118e fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=2ms status=304 bytes=175
2016-08-24T19:29:48.873064+00:00 heroku[router]: at=info method=GET path="/static/img/map.85bd42badf89.jpg" host=jsayapina.herokuapp.com request_id=92a8d989-4dcf-4342-814f-3f5a1a81e5b6 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=1ms service=2ms status=304 bytes=152
2016-08-24T19:29:48.751802+00:00 heroku[router]: at=info method=GET path="/static/styles/style.922a03ea63af.css" host=jsayapina.herokuapp.com request_id=50130b97-7f62-4326-8255-08f9f1dff2c8 fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=3ms status=304 bytes=175
2016-08-24T19:29:48.752725+00:00 heroku[router]: at=info method=GET path="/static/img/git.d3c6f2d124dc.png" host=jsayapina.herokuapp.com request_id=55e9613d-3299-41e0-97ab-afca84c1229f fwd="10.38.102.18,147.85.186.6" dyno=web.1 connect=0ms service=3ms status=304 bytes=152
2016-08-24T19:30:18.958216+00:00 heroku[router]: at=info method=GET path="/static/img/map.85bd42badf89.jpg" host=jsayapina.herokuapp.com request_id=277e0425-ebf5-4a33-bcd8-e38423d8784c fwd="147.85.186.6" dyno=web.1 connect=0ms service=5ms status=200 bytes=116505
2016-08-24T19:30:18.890284+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=6a0fd42c-15fe-4842-924d-66dfac7ec727 fwd="147.85.186.6" dyno=web.1 connect=1ms service=63ms status=500 bytes=3867
2016-08-24T19:30:19.012915+00:00 heroku[router]: at=info method=GET path="/static/img/logo.5c2c14584915.png" host=jsayapina.herokuapp.com request_id=3b0c1cb5-6bc7-4c42-9a36-e69d86839f26 fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=914
2016-08-24T19:30:18.983631+00:00 heroku[router]: at=info method=GET path="/static/js/script.d5ecb4c1ee49.js" host=jsayapina.herokuapp.com request_id=f2e7c5ac-f5a5-42ea-81b3-542b93650ece fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=563
2016-08-24T19:30:19.030047+00:00 heroku[router]: at=info method=GET path="/static/img/git.d3c6f2d124dc.png" host=jsayapina.herokuapp.com request_id=d8239199-2440-46b2-b5e7-9c67a3beb3f2 fwd="147.85.186.6" dyno=web.1 connect=0ms service=3ms status=200 bytes=73044
2016-08-24T19:30:19.044557+00:00 heroku[router]: at=info method=GET path="/static/img/favicon.1a6bc2acd77e.ico" host=jsayapina.herokuapp.com request_id=601ef10c-9caf-4a4f-b893-960a077b464d fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=12986
2016-08-24T19:30:19.003788+00:00 heroku[router]: at=info method=GET path="/static/img/supernova.a6060279447b.png" host=jsayapina.herokuapp.com request_id=b4829ccb-412f-405e-adf1-d8497d1c444c fwd="147.85.186.6" dyno=web.1 connect=1ms service=7ms status=200 bytes=163298
2016-08-24T19:30:18.969588+00:00 heroku[router]: at=info method=GET path="/static/styles/style.922a03ea63af.css" host=jsayapina.herokuapp.com request_id=d6f93a5c-8683-4568-9ee7-ffe7e704ed7d fwd="147.85.186.6" dyno=web.1 connect=3ms service=3ms status=200 bytes=2558
2016-08-24T19:30:23.268473+00:00 heroku[router]: at=info method=GET path="/static/img/pdf.png" host=jsayapina.herokuapp.com request_id=0e06a787-912f-42d2-9981-a6954d0f664f fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=706
2016-08-24T19:30:23.066221+00:00 heroku[router]: at=info method=GET path="/contacts" host=jsayapina.herokuapp.com request_id=26bcd595-8335-45c2-abce-b6a85eb1afac fwd="147.85.186.6" dyno=web.1 connect=0ms service=2ms status=301 bytes=239
2016-08-24T19:30:23.096016+00:00 heroku[router]: at=info method=GET path="/contacts/" host=jsayapina.herokuapp.com request_id=b6431a47-4c5d-4414-9d6a-9240ef9e9e11 fwd="147.85.186.6" dyno=web.1 connect=1ms service=5ms status=200 bytes=4990
2016-08-24T19:30:23.246445+00:00 heroku[router]: at=info method=GET path="/static/img/pin.5652a37c32cd.png" host=jsayapina.herokuapp.com request_id=d195f2ea-a562-45c6-8653-b055eeb7a0ee fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=2072
2016-08-24T19:30:23.176610+00:00 heroku[router]: at=info method=GET path="/static/img/email.4576eb21a471.png" host=jsayapina.herokuapp.com request_id=61869eb5-ff5b-47dd-8275-e43ad29e2ef6 fwd="147.85.186.6" dyno=web.1 connect=0ms service=1ms status=200 bytes=10094
2016-08-24T19:30:27.267909+00:00 heroku[router]: at=info method=GET path="/static/img/link.8c78d70fce25.png" host=jsayapina.herokuapp.com request_id=97e43205-9b25-41f9-a421-14782ee0479e fwd="147.85.186.6" dyno=web.1 connect=0ms service=2ms status=200 bytes=16854
2016-08-24T19:30:27.283516+00:00 heroku[router]: at=info method=GET path="/exp/" host=jsayapina.herokuapp.com request_id=c9e797fc-dfa0-4341-84ce-582f5ebc8e7c fwd="147.85.186.6" dyno=web.1 connect=0ms service=59ms status=200 bytes=10162
2016-08-24T19:30:27.357867+00:00 heroku[router]: at=info method=GET path="/static/js/script-exp.ab32bc45c25b.js" host=jsayapina.herokuapp.com request_id=79fccfc1-8167-47e0-b9d8-5797de35ae23 fwd="147.85.186.6" dyno=web.1 connect=0ms service=2ms status=200 bytes=738
2016-08-24T19:30:27.202351+00:00 heroku[router]: at=info method=GET path="/exp" host=jsayapina.herokuapp.com request_id=25954fe4-185a-4e19-9d67-aa037cf338ac fwd="147.85.186.6" dyno=web.1 connect=3ms service=2ms status=301 bytes=234
2016-08-24T19:49:06.839123+00:00 heroku[router]: at=info method=GET path="/edu/" host=jsayapina.herokuapp.com request_id=59410fbf-1ac5-487b-b277-7a88e9610b7b fwd="109.67.198.77" dyno=web.1 connect=0ms service=380ms status=200 bytes=10780
2016-08-24T19:49:16.198399+00:00 heroku[router]: at=info method=GET path="/exp/" host=jsayapina.herokuapp.com request_id=6a26a9d5-fc56-48f1-97e4-7d8ea501f465 fwd="109.67.198.77" dyno=web.1 connect=0ms service=59ms status=200 bytes=10162
2016-08-24T19:49:18.765006+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=1f7bb830-15d3-4b09-b4b3-9d1cda29ff98 fwd="109.67.198.77" dyno=web.1 connect=0ms service=108ms status=500 bytes=3867
2016-08-24T19:49:22.996201+00:00 heroku[router]: at=info method=GET path="/" host=jsayapina.herokuapp.com request_id=c4d218a5-e770-4926-aac0-4079834dafbe fwd="109.67.198.77" dyno=web.1 connect=1ms service=9ms status=200 bytes=3696
2016-08-24T20:23:38.509689+00:00 heroku[web.1]: Idling
2016-08-24T20:23:38.510886+00:00 heroku[web.1]: State changed from up to down
2016-08-24T20:23:43.218289+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2016-08-24T20:23:44.556926+00:00 app[web.1]: [2016-08-24 20:23:44 +0000] [8] [INFO] Worker exiting (pid: 8)
2016-08-24T20:23:44.751564+00:00 app[web.1]: [2016-08-24 20:23:44 +0000] [3] [INFO] Shutting down: Master
2016-08-24T20:23:44.640582+00:00 app[web.1]: [2016-08-24 20:23:44 +0000] [3] [INFO] Handling signal: term
2016-08-24T20:23:44.553956+00:00 app[web.1]: [2016-08-24 20:23:44 +0000] [7] [INFO] Worker exiting (pid: 7)
2016-08-24T20:23:45.193446+00:00 heroku[web.1]: Process exited with status 0
2016-08-25T10:02:49.109276+00:00 heroku[web.1]: Unidling
2016-08-25T10:02:49.109682+00:00 heroku[web.1]: State changed from down to starting
2016-08-25T10:02:55.802683+00:00 heroku[web.1]: Starting process with command `gunicorn portfolio.wsgi`
2016-08-25T10:02:58.457485+00:00 app[web.1]: [2016-08-25 10:02:58 +0000] [3] [INFO] Starting gunicorn 19.6.0
2016-08-25T10:02:58.458380+00:00 app[web.1]: [2016-08-25 10:02:58 +0000] [3] [INFO] Listening at: http://0.0.0.0:16460 (3)
2016-08-25T10:02:58.458530+00:00 app[web.1]: [2016-08-25 10:02:58 +0000] [3] [INFO] Using worker: sync
2016-08-25T10:02:58.463789+00:00 app[web.1]: [2016-08-25 10:02:58 +0000] [7] [INFO] Booting worker with pid: 7
2016-08-25T10:02:58.538090+00:00 app[web.1]: [2016-08-25 10:02:58 +0000] [8] [INFO] Booting worker with pid: 8
2016-08-25T10:02:59.497293+00:00 heroku[web.1]: State changed from starting to up
2016-08-25T10:03:03.163324+00:00 heroku[router]: at=info method=GET path="/port/" host=jsayapina.herokuapp.com request_id=6341d779-4b7d-4e4d-88a3-1b4c4de1c470 fwd="109.67.198.77" dyno=web.1 connect=1ms service=1996ms status=500 bytes=3867
我无法跟踪错误,因为滚动条对我来说无法正常工作(我想错误的配置,我的错误)和getsentry会花钱。
url to route / port /:
url(r'^port/', port),
views.py:
def port(request):
menu = 'disabled'
prs = Projects.objects.all()
return render(request, 'port1.html', {"prs": prs, "menu0": menu})
port1.html:
{%extends'base.html'%} {%load staticfiles%}
{% block title %}
<title>Portfolio</title>
{% endblock %}
{% block caption %}
<h1 class="col-sm-8">Projects</h1>
{% endblock %}
{% block menu1 %}disabled{% endblock %}
{% block content %}
<div class="container-fluid contacto">
<div id="main">
<div class="inner">
<section class="tiles">
{% for p in prs %}
<article class="{{p.style}}">
<span class="image">
<img src="{{p.img}}" alt="{{p.name}}" />
</span>
<a href="{{p.site}}" target="blank">
<h2 class="port">{{p.name}}</h2>
<div class="content">
<p>{{p.desc}}</p>
</div>
</a>
</article>
{% endfor %}
</section>
</div>
</div>
</div>
{% endblock %}
{% block js%}
<script src={% static "assets/js/jquery.min.js" %}></script>
<script src={% static "assets/js/skel.min.js" %}></script>
<script src={% static "assets/js/util.min.js" %}></script>
<!--[if lte IE 8]><script src="{% static "assets/js/ie/respond.min.js" %}"></script><![endif]-->
<script src={% static "assets/js/main.js" %}></script>
{% endblock %}
数据库工作正常并且充满了数据。其他一切都很完美。在localhost上一切正常(包括此/ port /)。 真的不知道它是什么。有什么建议吗?
抱歉noob问题,我是新手,这是我第一次在Heroku上部署)并且曾经))
感谢大家!
答案 0 :(得分:0)
def port(request):
try:
menu = 'disabled'
prs = Projects.objects.all()
except:
import sys
print str(sys.exc_info())
return render(request, 'port1.html', {"prs": prs, "menu0": menu})
尝试打印例外。我希望这会打印在日志上。
答案 1 :(得分:0)
事实上后来我找到了另一种非常有用的跟踪方式--Django可以向管理员发送错误邮件。简单地将其添加到setting.py是成功的关键:
ADMINS = (('username', 'user@domain.com'),)
MANAGERS = ADMINSEMAIL_HOST = 'host'
SEND_BROKEN_LINK_EMAILS=True
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_PORT = 587
EMAIL_HOST_USER = 'username'
EMAIL_HOST_PASSWORD = 'password'
EMAIL_USE_TLS = True
SERVER_EMAIL = 'django@my-domain.com'
EMAIL_HOST = 'smtp.gmail.com'
SERVER_EMAIL = EMAIL_HOST_USER
文档:https://docs.djangoproject.com/en/1.7/howto/error-reporting/