Heroku(Django Web 应用程序)上的应用程序错误
我正在尝试在 Heroku 上部署我的 Django Web 应用程序。构建成功,但我仍然收到应用程序错误。以下是我的应用程序的日志。
日志:
2022-03-04T12:47:48.701018+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
2022-03-04T12:47:48.701018+00:00 app[web.1]: ModuleNotFoundError: No module named 'SASTRAScrapper'
2022-03-04T12:47:48.701025+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [9] [INFO] Worker exiting (pid: 9)
2022-03-04T12:47:48.745701+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [WARNING] Worker with pid 9 was terminated due to signal 15
2022-03-04T12:47:48.841738+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [INFO] Shutting down: Master
2022-03-04T12:47:48.841740+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [INFO] Reason: Worker failed to boot.
2022-03-04T12:47:49.032701+00:00 heroku[web.1]: Process exited with status 3
2022-03-04T12:47:49.097253+00:00 heroku[web.1]: State changed from up to crashed
2022-03-04T12:48:02.499473+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=f5454869-83fe-41bc-a081-a0b11b419ad1 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:48:03.140143+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=8e31ba10-6112-41f6-b8f8-6c58e86acb4a fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:00.300756+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=e0c472d9-2ce4-4c99-9048-87e95a834255 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:00.916514+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=f4a4d43f-aa19-4784-9602-f897e2a71238 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:04.938317+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=8e3167e6-c97e-42e7-8fe0-1e2a5136acc4 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:05.403850+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=42a92e54-37cc-483d-8766-081783ac8695 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:27.736824+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=1e7767fc-74d8-4c4d-917d-a5e39c798823 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:28.323634+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=41740811-72fc-4360-90f3-4d14a3c27b96 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
请帮助我!
I am trying to deploy my Django web-app on Heroku. Build succeeds but still I get an Application Error. Below are my app's logs.
Logs:
2022-03-04T12:47:48.701018+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 984, in _find_and_load_unlocked
2022-03-04T12:47:48.701018+00:00 app[web.1]: ModuleNotFoundError: No module named 'SASTRAScrapper'
2022-03-04T12:47:48.701025+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [9] [INFO] Worker exiting (pid: 9)
2022-03-04T12:47:48.745701+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [WARNING] Worker with pid 9 was terminated due to signal 15
2022-03-04T12:47:48.841738+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [INFO] Shutting down: Master
2022-03-04T12:47:48.841740+00:00 app[web.1]: [2022-03-04 12:47:48 +0000] [4] [INFO] Reason: Worker failed to boot.
2022-03-04T12:47:49.032701+00:00 heroku[web.1]: Process exited with status 3
2022-03-04T12:47:49.097253+00:00 heroku[web.1]: State changed from up to crashed
2022-03-04T12:48:02.499473+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=f5454869-83fe-41bc-a081-a0b11b419ad1 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:48:03.140143+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=8e31ba10-6112-41f6-b8f8-6c58e86acb4a fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:00.300756+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=e0c472d9-2ce4-4c99-9048-87e95a834255 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:00.916514+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=f4a4d43f-aa19-4784-9602-f897e2a71238 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:04.938317+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=8e3167e6-c97e-42e7-8fe0-1e2a5136acc4 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:05.403850+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=42a92e54-37cc-483d-8766-081783ac8695 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:27.736824+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=sastra-scraper.herokuapp.com request_id=1e7767fc-74d8-4c4d-917d-a5e39c798823 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
2022-03-04T12:49:28.323634+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=sastra-scraper.herokuapp.com request_id=41740811-72fc-4360-90f3-4d14a3c27b96 fwd="122.161.254.213" dyno= connect= service= status=503 bytes= protocol=https
Kindly help me out!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您的
SASTRAScraper/wsgi.py
中有一个拼写错误。更改
为
使其与实际目录名称匹配。
此拼写错误也存在于
SASTRAScraper/asgi.py
中,并且在SASTRAScraper/urls.py
中也存在注释。我怀疑您在第一次运行 django-admin.py startproject 时拼写错误。You have a typo in your
SASTRAScraper/wsgi.py
.Change
to
so it matches the actual directory name.
This typo is also present in
SASTRAScraper/asgi.py
and a comment inSASTRAScraper/urls.py
. I suspect you spelled this the wrong way when you first randjango-admin.py startproject
.