When gunicorn can't boot up properly the traceback error is not helpful.
Traceback (most recent call last):
File "/layers/google.python.pip/pip/lib/python3.11/site-packages/gunicorn/arbiter.py", line 609, in spawn_worker
worker.init_process()
File "/layers/google.python.pip/pip/lib/python3.11/site-packages/gunicorn/workers/gthread.py", line 95, in init_process
super().init_process()
File "/layers/google.python.pip/pip/lib/python3.11/site-packages/gunicorn/workers/base.py", line 134, in init_process
self.load_wsgi()
File "/layers/google.python.pip/pip/lib/python3.11/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi
self.wsgi = self.app.wsgi()
The actual error was hidden in the logs and not higlighted as one.
google.api_core.exceptions.Forbidden: 403 GET https://storage.googleapis.com/storage/v1/b/application-name.appspot.com?projection=noAcl&prettyPrint=false: application-name@appspot.gserviceaccount.com does not have storage.buckets.get access to the Google Cloud Storage bucket. Permission 'storage.buckets.get' denied on resource (or it may not exist).
When gunicorn can't boot up properly the traceback error is not helpful.
The actual error was hidden in the logs and not higlighted as one.