-
Notifications
You must be signed in to change notification settings - Fork 5k
Description
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
Ask a question and submit on chat with your data page. Error in response.
When clicking on ask a question the completion and response is received ok from data.
Not sure what the issue is, logs below
Any log messages given by the failure
2023-10-10T10:05:43.130337042Z [2023-10-10 10:05:43 +0000] [74] [ERROR] Exception in ASGI application
2023-10-10T10:05:43.131131041Z Traceback (most recent call last):
2023-10-10T10:05:43.131141341Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/uvicorn/protocols/http/httptools_impl.py", line 426, in run_asgi
2023-10-10T10:05:43.131145641Z result = await app( # type: ignore[func-returns-value]
2023-10-10T10:05:43.131148941Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call
2023-10-10T10:05:43.131152441Z return await self.app(scope, receive, send)
2023-10-10T10:05:43.131155741Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/app.py", line 1620, in call
2023-10-10T10:05:43.131159041Z await self.asgi_app(scope, receive, send)
2023-10-10T10:05:43.131162341Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/opentelemetry/instrumentation/asgi/init.py", line 596, in call
2023-10-10T10:05:43.131174841Z await self.app(scope, otel_receive, otel_send)
2023-10-10T10:05:43.131178341Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/app.py", line 1646, in asgi_app
2023-10-10T10:05:43.131181441Z await asgi_handler(receive, send)
2023-10-10T10:05:43.131184741Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/asgi.py", line 52, in call
2023-10-10T10:05:43.131187841Z raise_task_exceptions(done)
2023-10-10T10:05:43.131190741Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/utils.py", line 187, in raise_task_exceptions
2023-10-10T10:05:43.131193941Z raise task.exception()
2023-10-10T10:05:43.131196841Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/asgi.py", line 107, in handle_request
2023-10-10T10:05:43.131199941Z await asyncio.wait_for(self._send_response(send, response), timeout=timeout)
2023-10-10T10:05:43.131203041Z File "/opt/python/3.10.12/lib/python3.10/asyncio/tasks.py", line 408, in wait_for
2023-10-10T10:05:43.131206041Z return await fut
2023-10-10T10:05:43.131209041Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/quart/asgi.py", line 134, in _send_response
2023-10-10T10:05:43.131235041Z async for data in response_body:
2023-10-10T10:05:43.131238341Z File "/tmp/8dbc9762d29380d/app.py", line 127, in format_as_ndjson
2023-10-10T10:05:43.131241441Z async for event in r:
2023-10-10T10:05:43.131244541Z File "/tmp/8dbc9762d29380d/approaches/chatreadretrieveread.py", line 237, in run_with_streaming
2023-10-10T10:05:43.131247741Z extra_info, chat_coroutine = await self.run_until_final_call(
2023-10-10T10:05:43.131250941Z File "/tmp/8dbc9762d29380d/approaches/chatreadretrieveread.py", line 119, in run_until_final_call
2023-10-10T10:05:43.131256141Z chat_completion = await openai.ChatCompletion.acreate(
2023-10-10T10:05:43.131259541Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/openai/api_resources/chat_completion.py", line 45, in acreate
2023-10-10T10:05:43.131262741Z return await super().acreate(*args, **kwargs)
2023-10-10T10:05:43.131265841Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 219, in acreate
2023-10-10T10:05:43.131269141Z response, _, api_key = await requestor.arequest(
2023-10-10T10:05:43.131272141Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/openai/api_requestor.py", line 384, in arequest
2023-10-10T10:05:43.131275341Z resp, got_stream = await self._interpret_async_response(result, stream)
2023-10-10T10:05:43.131278541Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/openai/api_requestor.py", line 738, in _interpret_async_response
2023-10-10T10:05:43.131285441Z self._interpret_response_line(
2023-10-10T10:05:43.131288641Z File "/tmp/8dbc9762d29380d/antenv/lib/python3.10/site-packages/openai/api_requestor.py", line 775, in _interpret_response_line
2023-10-10T10:05:43.131295841Z raise self.handle_error_response(
2023-10-10T10:05:43.131299041Z openai.error.InvalidRequestError: Unrecognized request argument supplied: functions
2023-10-10T10:05:43.174373581Z �[41m�[30mfail�[39m�[22m�[49m: Middleware[0]
2023-10-10T10:05:43.174412381Z Failed to forward request to http://169.254.130.33:8000. Encountered a System.IO.IOException exception after 1767.901ms with message: The response ended prematurely.. Check application logs to verify the application is properly handling HTTP traffic.
Expected/desired behavior
OS and Version?
Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)
azd version?
run
azd versionand copy paste here.
latest
Versions
occurs with Python 3.10 and 3.11 for dev container and app runtime.
Mention any other details that might be useful
Thanks! We'll be in touch soon.