azure-search-openai-demo icon indicating copy to clipboard operation
azure-search-openai-demo copied to clipboard

Webapp no more starting

Open superpoussin22 opened this issue 1 year ago • 3 comments

Please provide us with the following information:

This issue is for a: (mark with an x)

- [X] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Deploy the app with last version and start it Sounds like an issue with opentelemetry packages

Any log messages given by the failure

2024-04-17T11:30:59.947657554Z [2024-04-17 11:30:59 +0000] [128] [ERROR] Exception in worker process 2024-04-17T11:30:59.947701854Z Traceback (most recent call last): 2024-04-17T11:30:59.947708454Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/arbiter.py", line 609, in spawn_worker 2024-04-17T11:30:59.947713454Z worker.init_process() 2024-04-17T11:30:59.947717453Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/uvicorn/workers.py", line 66, in init_process 2024-04-17T11:30:59.947721453Z super(UvicornWorker, self).init_process() 2024-04-17T11:30:59.947725453Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 134, in init_process 2024-04-17T11:30:59.947729553Z self.load_wsgi() 2024-04-17T11:30:59.947733253Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi 2024-04-17T11:30:59.947737653Z self.wsgi = self.app.wsgi() 2024-04-17T11:30:59.947741553Z ^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.947745453Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/base.py", line 67, in wsgi 2024-04-17T11:30:59.947749553Z self.callable = self.load() 2024-04-17T11:30:59.947753353Z ^^^^^^^^^^^ 2024-04-17T11:30:59.947757153Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 58, in load 2024-04-17T11:30:59.947761253Z return self.load_wsgiapp() 2024-04-17T11:30:59.947771553Z ^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.947775253Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp 2024-04-17T11:30:59.947800652Z return util.import_app(self.app_uri) 2024-04-17T11:30:59.947804752Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.947808652Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/util.py", line 371, in import_app 2024-04-17T11:30:59.947812652Z mod = importlib.import_module(module) 2024-04-17T11:30:59.947816552Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.947820352Z File "/opt/python/3.11.7/lib/python3.11/importlib/init.py", line 126, in import_module 2024-04-17T11:30:59.947824452Z return _bootstrap._gcd_import(name[level:], package, level) 2024-04-17T11:30:59.947828252Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.947832152Z File "", line 1204, in _gcd_import 2024-04-17T11:30:59.947846051Z File "", line 1176, in _find_and_load 2024-04-17T11:30:59.947850651Z File "", line 1147, in _find_and_load_unlocked 2024-04-17T11:30:59.947854651Z File "", line 690, in _load_unlocked 2024-04-17T11:30:59.947858651Z File "", line 940, in exec_module 2024-04-17T11:30:59.947862751Z File "", line 241, in _call_with_frames_removed 2024-04-17T11:30:59.947867751Z File "/tmp/8dc5ec898960094/main.py", line 1, in 2024-04-17T11:30:59.947872051Z from app import create_app 2024-04-17T11:30:59.947875851Z File "/tmp/8dc5ec898960094/app.py", line 23, in 2024-04-17T11:30:59.947879851Z from opentelemetry.instrumentation.aiohttp_client import AioHttpClientInstrumentor 2024-04-17T11:30:59.947883951Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/opentelemetry/instrumentation/aiohttp_client/init.py", line 96, in 2024-04-17T11:30:59.947888251Z from opentelemetry.instrumentation.utils import ( 2024-04-17T11:30:59.947892151Z ImportError: cannot import name 'is_instrumentation_enabled' from 'opentelemetry.instrumentation.utils' (/agents/python/opentelemetry/instrumentation/utils.py) 2024-04-17T11:30:59.947896251Z [2024-04-17 11:30:59 +0000] [128] [INFO] Worker exiting (pid: 128) 2024-04-17T11:30:59.957741696Z [2024-04-17 11:30:59 +0000] [108] [ERROR] Exception in worker process 2024-04-17T11:30:59.957768196Z Traceback (most recent call last): 2024-04-17T11:30:59.957774596Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/arbiter.py", line 609, in spawn_worker 2024-04-17T11:30:59.957779296Z worker.init_process() 2024-04-17T11:30:59.957783096Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/uvicorn/workers.py", line 66, in init_process 2024-04-17T11:30:59.957787496Z super(UvicornWorker, self).init_process() 2024-04-17T11:30:59.957791295Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 134, in init_process 2024-04-17T11:30:59.957795395Z self.load_wsgi() 2024-04-17T11:30:59.957799195Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi 2024-04-17T11:30:59.957821695Z self.wsgi = self.app.wsgi() 2024-04-17T11:30:59.957825795Z ^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.957829795Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/base.py", line 67, in wsgi 2024-04-17T11:30:59.957833995Z self.callable = self.load() 2024-04-17T11:30:59.957837895Z ^^^^^^^^^^^ 2024-04-17T11:30:59.957841795Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 58, in load 2024-04-17T11:30:59.957855494Z return self.load_wsgiapp() 2024-04-17T11:30:59.957859894Z ^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.957863794Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp 2024-04-17T11:30:59.957868094Z return util.import_app(self.app_uri) 2024-04-17T11:30:59.957872094Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.957875894Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/util.py", line 371, in import_app 2024-04-17T11:30:59.957879994Z mod = importlib.import_module(module) 2024-04-17T11:30:59.957883894Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.957887794Z File "/opt/python/3.11.7/lib/python3.11/importlib/init.py", line 126, in import_module 2024-04-17T11:30:59.957891994Z return _bootstrap._gcd_import(name[level:], package, level) 2024-04-17T11:30:59.957895994Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:30:59.957899994Z File "", line 1204, in _gcd_import 2024-04-17T11:30:59.957904794Z File "", line 1176, in _find_and_load 2024-04-17T11:30:59.957908894Z File "", line 1147, in _find_and_load_unlocked 2024-04-17T11:30:59.957912994Z File "", line 690, in _load_unlocked 2024-04-17T11:30:59.957917094Z File "", line 940, in exec_module 2024-04-17T11:30:59.957921393Z File "", line 241, in _call_with_frames_removed 2024-04-17T11:30:59.957926293Z File "/tmp/8dc5ec898960094/main.py", line 1, in 2024-04-17T11:30:59.957930593Z from app import create_app 2024-04-17T11:30:59.957934493Z File "/tmp/8dc5ec898960094/app.py", line 23, in 2024-04-17T11:30:59.957938693Z from opentelemetry.instrumentation.aiohttp_client import AioHttpClientInstrumentor 2024-04-17T11:30:59.957942793Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/opentelemetry/instrumentation/aiohttp_client/init.py", line 96, in 2024-04-17T11:30:59.957947093Z from opentelemetry.instrumentation.utils import ( 2024-04-17T11:30:59.957950993Z ImportError: cannot import name 'is_instrumentation_enabled' from 'opentelemetry.instrumentation.utils' (/agents/python/opentelemetry/instrumentation/utils.py) 2024-04-17T11:30:59.967453044Z [2024-04-17 11:30:59 +0000] [108] [INFO] Worker exiting (pid: 108) 2024-04-17T11:31:00.025989626Z [2024-04-17 11:31:00 +0000] [118] [ERROR] Exception in worker process 2024-04-17T11:31:00.026028125Z Traceback (most recent call last): 2024-04-17T11:31:00.026034425Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/arbiter.py", line 609, in spawn_worker 2024-04-17T11:31:00.026039025Z worker.init_process() 2024-04-17T11:31:00.026056025Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/uvicorn/workers.py", line 66, in init_process 2024-04-17T11:31:00.026060825Z super(UvicornWorker, self).init_process() 2024-04-17T11:31:00.026064725Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 134, in init_process 2024-04-17T11:31:00.026068925Z self.load_wsgi() 2024-04-17T11:31:00.026073025Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi 2024-04-17T11:31:00.026077225Z self.wsgi = self.app.wsgi() 2024-04-17T11:31:00.026081225Z ^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.026085125Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/base.py", line 67, in wsgi 2024-04-17T11:31:00.026089324Z self.callable = self.load() 2024-04-17T11:31:00.026093124Z ^^^^^^^^^^^ 2024-04-17T11:31:00.026097024Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 58, in load 2024-04-17T11:31:00.026101624Z return self.load_wsgiapp() 2024-04-17T11:31:00.026105724Z ^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.026109624Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp 2024-04-17T11:31:00.026113824Z return util.import_app(self.app_uri) 2024-04-17T11:31:00.026117724Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.026121624Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/util.py", line 371, in import_app 2024-04-17T11:31:00.026125724Z mod = importlib.import_module(module) 2024-04-17T11:31:00.026129624Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.026133524Z File "/opt/python/3.11.7/lib/python3.11/importlib/init.py", line 126, in import_module 2024-04-17T11:31:00.026137724Z return _bootstrap._gcd_import(name[level:], package, level) 2024-04-17T11:31:00.026141724Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.026145624Z File "", line 1204, in _gcd_import 2024-04-17T11:31:00.026150124Z File "", line 1176, in _find_and_load 2024-04-17T11:31:00.026154323Z File "", line 1147, in _find_and_load_unlocked 2024-04-17T11:31:00.026158323Z File "", line 690, in _load_unlocked 2024-04-17T11:31:00.026162423Z File "", line 940, in exec_module 2024-04-17T11:31:00.026166523Z File "", line 241, in _call_with_frames_removed 2024-04-17T11:31:00.026171723Z File "/tmp/8dc5ec898960094/main.py", line 1, in 2024-04-17T11:31:00.026176023Z from app import create_app 2024-04-17T11:31:00.026183623Z File "/tmp/8dc5ec898960094/app.py", line 23, in 2024-04-17T11:31:00.026188023Z from opentelemetry.instrumentation.aiohttp_client import AioHttpClientInstrumentor 2024-04-17T11:31:00.026192123Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/opentelemetry/instrumentation/aiohttp_client/init.py", line 96, in 2024-04-17T11:31:00.026196523Z from opentelemetry.instrumentation.utils import ( 2024-04-17T11:31:00.026200523Z ImportError: cannot import name 'is_instrumentation_enabled' from 'opentelemetry.instrumentation.utils' (/agents/python/opentelemetry/instrumentation/utils.py) 2024-04-17T11:31:00.031780135Z [2024-04-17 11:31:00 +0000] [118] [INFO] Worker exiting (pid: 118) 2024-04-17T11:31:00.193856594Z [2024-04-17 11:31:00 +0000] [131] [ERROR] Exception in worker process 2024-04-17T11:31:00.193897793Z Traceback (most recent call last): 2024-04-17T11:31:00.193904793Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/arbiter.py", line 609, in spawn_worker 2024-04-17T11:31:00.193909693Z worker.init_process() 2024-04-17T11:31:00.193913693Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/uvicorn/workers.py", line 66, in init_process 2024-04-17T11:31:00.193918093Z super(UvicornWorker, self).init_process() 2024-04-17T11:31:00.193922893Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 134, in init_process 2024-04-17T11:31:00.193927193Z self.load_wsgi() 2024-04-17T11:31:00.193930992Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi 2024-04-17T11:31:00.193935092Z self.wsgi = self.app.wsgi() 2024-04-17T11:31:00.193938992Z ^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.193942892Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/base.py", line 67, in wsgi 2024-04-17T11:31:00.193947792Z self.callable = self.load() 2024-04-17T11:31:00.193951692Z ^^^^^^^^^^^ 2024-04-17T11:31:00.193955592Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 58, in load 2024-04-17T11:31:00.193959692Z return self.load_wsgiapp() 2024-04-17T11:31:00.193963592Z ^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.193967592Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp 2024-04-17T11:31:00.193971892Z return util.import_app(self.app_uri) 2024-04-17T11:31:00.193975892Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.193979892Z File "/opt/python/3.11.7/lib/python3.11/site-packages/gunicorn/util.py", line 371, in import_app 2024-04-17T11:31:00.193984092Z mod = importlib.import_module(module) 2024-04-17T11:31:00.193987992Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.193991892Z File "/opt/python/3.11.7/lib/python3.11/importlib/init.py", line 126, in import_module 2024-04-17T11:31:00.194009791Z return _bootstrap._gcd_import(name[level:], package, level) 2024-04-17T11:31:00.194014191Z ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 2024-04-17T11:31:00.194018091Z File "", line 1204, in _gcd_import 2024-04-17T11:31:00.194022791Z File "", line 1176, in _find_and_load 2024-04-17T11:31:00.194026791Z File "", line 1147, in _find_and_load_unlocked 2024-04-17T11:31:00.194030891Z File "", line 690, in _load_unlocked 2024-04-17T11:31:00.194034991Z File "", line 940, in exec_module 2024-04-17T11:31:00.194039091Z File "", line 241, in _call_with_frames_removed 2024-04-17T11:31:00.194044991Z File "/tmp/8dc5ec898960094/main.py", line 1, in 2024-04-17T11:31:00.194049191Z from app import create_app 2024-04-17T11:31:00.194053091Z File "/tmp/8dc5ec898960094/app.py", line 23, in 2024-04-17T11:31:00.194057190Z from opentelemetry.instrumentation.aiohttp_client import AioHttpClientInstrumentor 2024-04-17T11:31:00.194061290Z File "/tmp/8dc5ec898960094/antenv/lib/python3.11/site-packages/opentelemetry/instrumentation/aiohttp_client/init.py", line 96, in 2024-04-17T11:31:00.194065690Z from opentelemetry.instrumentation.utils import ( 2024-04-17T11:31:00.194069690Z ImportError: cannot import name 'is_instrumentation_enabled' from 'opentelemetry.instrumentation.utils' (/agents/python/opentelemetry/instrumentation/utils.py) 2024-04-17T11:31:00.208234368Z [2024-04-17 11:31:00 +0000] [131] [INFO] Worker exiting (pid: 131)

Expected/desired behavior

OS and Version?

Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)

azd version?

run azd version and copy paste here.

Versions

Mention any other details that might be useful


Thanks! We'll be in touch soon.

superpoussin22 avatar Apr 17 '24 11:04 superpoussin22

desactivating the appinsights solve the issue , but need to understand what such issue occurs

superpoussin22 avatar Apr 17 '24 12:04 superpoussin22

omg!! I literally spent 8 hours trying to figure out the issue. Thanks to this post. I just remembered after reading the post that the error began right after I enabled app insights!! 👎

laykayfals avatar Apr 23 '24 00:04 laykayfals

For anyone reading, a quick reference:

azd env set AZURE_USE_APPLICATION_INSIGHTS false

laneparton avatar May 03 '24 10:05 laneparton