Skip to main content

code=H10 desc="App crashed" Heroku Application error

I am trying to deploy an ML model using Flask on Heroku but the application keeps failing. I checked the logs and this is what I get to be the errors.

2021-05-30T23:40:59.657322+00:00 app[web.1]: File "/app/wsgi.py", line 1, in <module>
2021-05-30T23:40:59.657322+00:00 app[web.1]: from app.app import app
2021-05-30T23:40:59.657322+00:00 app[web.1]: ModuleNotFoundError: No module named 'app.app'; 'app' is not a package
2021-05-30T23:40:59.657552+00:00 app[web.1]: [2021-05-30 23:40:59 +0000] [9] [INFO] Worker exiting (pid: 9)
2021-05-30T23:40:59.660745+00:00 app[web.1]: [2021-05-30 23:40:59 +0000] [8] [ERROR] Exception in worker process
2021-05-30T23:40:59.660746+00:00 app[web.1]: Traceback (most recent call last):
2021-05-30T23:40:59.660747+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 589, in spawn_worker
2021-05-30T23:40:59.660748+00:00 app[web.1]: worker.init_process()
2021-05-30T23:40:59.660749+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/workers/base.py", line 134, in init_process
2021-05-30T23:40:59.660749+00:00 app[web.1]: self.load_wsgi()
2021-05-30T23:40:59.660749+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi
2021-05-30T23:40:59.660750+00:00 app[web.1]: self.wsgi = self.app.wsgi()
2021-05-30T23:40:59.660751+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/base.py", line 67, in wsgi
2021-05-30T23:40:59.660751+00:00 app[web.1]: self.callable = self.load()
2021-05-30T23:40:59.660751+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/wsgiapp.py", line 58, in load
2021-05-30T23:40:59.660752+00:00 app[web.1]: return self.load_wsgiapp()
2021-05-30T23:40:59.660752+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp
2021-05-30T23:40:59.660753+00:00 app[web.1]: return util.import_app(self.app_uri)
2021-05-30T23:40:59.660753+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/util.py", line 359, in import_app
2021-05-30T23:40:59.660753+00:00 app[web.1]: mod = importlib.import_module(module)
2021-05-30T23:40:59.660754+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/importlib/__init__.py", line 127, in import_module
2021-05-30T23:40:59.660754+00:00 app[web.1]: return _bootstrap._gcd_import(name[level:], package, level)
2021-05-30T23:40:59.660755+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
2021-05-30T23:40:59.660755+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 991, in _find_and_load
2021-05-30T23:40:59.660755+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
2021-05-30T23:40:59.660756+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
2021-05-30T23:40:59.660756+00:00 app[web.1]: File "<frozen importlib._bootstrap_external>", line 783, in exec_module
2021-05-30T23:40:59.660756+00:00 app[web.1]: File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
2021-05-30T23:40:59.660757+00:00 app[web.1]: File "/app/wsgi.py", line 1, in <module>
2021-05-30T23:40:59.660757+00:00 app[web.1]: from app.app import app
2021-05-30T23:40:59.660757+00:00 app[web.1]: ModuleNotFoundError: No module named 'app.app'; 'app' is not a package
2021-05-30T23:40:59.661044+00:00 app[web.1]: [2021-05-30 23:40:59 +0000] [8] [INFO] Worker exiting (pid: 8)
2021-05-30T23:40:59.791609+00:00 app[web.1]: Traceback (most recent call last):
2021-05-30T23:40:59.791662+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 209, in run
2021-05-30T23:40:59.792162+00:00 app[web.1]: self.sleep()
2021-05-30T23:40:59.792195+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 357, in sleep
2021-05-30T23:40:59.792662+00:00 app[web.1]: ready = select.select([self.PIPE[0]], [], [], 1.0)
2021-05-30T23:40:59.792694+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 242, in handle_chld
2021-05-30T23:40:59.793035+00:00 app[web.1]: self.reap_workers()
2021-05-30T23:40:59.793060+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 525, in reap_workers
2021-05-30T23:40:59.793506+00:00 app[web.1]: raise HaltServer(reason, self.WORKER_BOOT_ERROR)
2021-05-30T23:40:59.793688+00:00 app[web.1]: gunicorn.errors.HaltServer: <HaltServer 'Worker failed to boot.' 3>
2021-05-30T23:40:59.793707+00:00 app[web.1]:
2021-05-30T23:40:59.793708+00:00 app[web.1]: During handling of the above exception, another exception occurred:
2021-05-30T23:40:59.793708+00:00 app[web.1]:
2021-05-30T23:40:59.793733+00:00 app[web.1]: Traceback (most recent call last):
2021-05-30T23:40:59.793759+00:00 app[web.1]: File "/app/.heroku/python/bin/gunicorn", line 8, in <module>
2021-05-30T23:40:59.794022+00:00 app[web.1]: sys.exit(run())
2021-05-30T23:40:59.794044+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/wsgiapp.py", line 67, in run
2021-05-30T23:40:59.794296+00:00 app[web.1]: WSGIApplication("%(prog)s [OPTIONS] [APP_MODULE]").run()
2021-05-30T23:40:59.794318+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/base.py", line 231, in run
2021-05-30T23:40:59.794671+00:00 app[web.1]: super().run()
2021-05-30T23:40:59.794695+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/app/base.py", line 72, in run
2021-05-30T23:40:59.794942+00:00 app[web.1]: Arbiter(self).run()
2021-05-30T23:40:59.795007+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 229, in run
2021-05-30T23:40:59.795492+00:00 app[web.1]: self.halt(reason=inst.reason, exit_status=inst.exit_status)
2021-05-30T23:40:59.795516+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 342, in halt
2021-05-30T23:40:59.795922+00:00 app[web.1]: self.stop()
2021-05-30T23:40:59.795946+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 393, in stop
2021-05-30T23:40:59.796400+00:00 app[web.1]: time.sleep(0.1)
2021-05-30T23:40:59.796427+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 242, in handle_chld
2021-05-30T23:40:59.796751+00:00 app[web.1]: self.reap_workers()
2021-05-30T23:40:59.796782+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.8/site-packages/gunicorn/arbiter.py", line 525, in reap_workers
2021-05-30T23:40:59.797247+00:00 app[web.1]: raise HaltServer(reason, self.WORKER_BOOT_ERROR)
2021-05-30T23:40:59.797373+00:00 app[web.1]: gunicorn.errors.HaltServer: <HaltServer 'Worker failed to boot.' 3>
2021-05-30T23:40:59.882701+00:00 heroku[web.1]: Process exited with status 1
2021-05-30T23:40:59.965187+00:00 heroku[web.1]: State changed from up to crashed
2021-05-30T23:46:22.786158+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=simple-lr-model.herokuapp.com request_id=14d024e3-5e3b-4f3e-86b1-b223f9fcea0d fwd="197.210.29.146" dyno= connect= service= status=503 bytes= protocol=https
2021-05-30T23:46:23.592882+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=simple-lr-model.herokuapp.com request_id=a7711329-41f2-4faa-9e1f-bd28a7be78ee fwd="197.210.29.146" dyno= connect= service= status=503 bytes= protocol=https

I have tried solutions such as heroku restart but did not work.

I also used heroku run rails console. It returned bash: rails: command not found.

I am not sure what to do right now! I see some ModuleNotFoundError and some code=H10 desc="App crashed" error in the end.

How can I possibly solve this? Thank you!



source https://stackoverflow.com/questions/67766700/code-h10-desc-app-crashed-heroku-application-error

Comments

Popular posts from this blog

Prop `className` did not match in next js app

I have written a sample code ( Github Link here ). this is a simple next js app, but giving me error when I refresh the page. This seems to be the common problem and I tried the fix provided in the internet but does not seem to fix my issue. The error is Warning: Prop className did not match. Server: "MuiBox-root MuiBox-root-1" Client: "MuiBox-root MuiBox-root-2". Did changes for _document.js, modified _app.js as mentioned in official website and solutions in stackoverflow. but nothing seems to work. Could someone take a look and help me whats wrong with the code? Via Active questions tagged javascript - Stack Overflow https://ift.tt/2FdjaAW

How to show number of registered users in Laravel based on usertype?

i'm trying to display data from the database in the admin dashboard i used this: <?php use Illuminate\Support\Facades\DB; $users = DB::table('users')->count(); echo $users; ?> and i have successfully get the correct data from the database but what if i want to display a specific data for example in this user table there is "usertype" that specify if the user is normal user or admin i want to user the same code above but to display a specific usertype i tried this: <?php use Illuminate\Support\Facades\DB; $users = DB::table('users')->count()->WHERE usertype =admin; echo $users; ?> but it didn't work, what am i doing wrong? source https://stackoverflow.com/questions/68199726/how-to-show-number-of-registered-users-in-laravel-based-on-usertype

Why is my reports service not connecting?

I am trying to pull some data from a Postgres database using Node.js and node-postures but I can't figure out why my service isn't connecting. my routes/index.js file: const express = require('express'); const router = express.Router(); const ordersCountController = require('../controllers/ordersCountController'); const ordersController = require('../controllers/ordersController'); const weeklyReportsController = require('../controllers/weeklyReportsController'); router.get('/orders_count', ordersCountController); router.get('/orders', ordersController); router.get('/weekly_reports', weeklyReportsController); module.exports = router; My controllers/weeklyReportsController.js file: const weeklyReportsService = require('../services/weeklyReportsService'); const weeklyReportsController = async (req, res) => { try { const data = await weeklyReportsService; res.json({data}) console