Could not create the AI provider assistant. See the Console for details.

I tried to use the openai in Wingpro's AI assistant, but failed as follows:

Starting AI Chat
/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/bin/python3.11 /usr/lib/wingpro10/plugins/ai/_openai_chat.py
WINGHOME=/usr/lib/wingpro10
WINGSETTINGSDIR=/home/werner/.wingpro10
STARTED=127.0.0.1:53789


Could not create AI Assistant:
Traceback (most recent call last):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_exceptions.py", line 10, in map_exceptions
    yield
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_backends/sync.py", line 206, in connect_tcp
    sock = socket.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/socket.py", line 827, in create_connection
    for res in getaddrinfo(host, port, 0, SOCK_STREAM):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/socket.py", line 962, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno -2] Name or service not known

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 67, in map_httpcore_exceptions
    yield
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 231, in handle_request
    resp = self._pool.handle_request(req)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection_pool.py", line 268, in handle_request
    raise exc
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection_pool.py", line 251, in handle_request
    response = connection.handle_request(request)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 99, in handle_request
    raise exc
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 76, in handle_request
    stream = self._connect(request)
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 124, in _connect
    stream = self._network_backend.connect_tcp(**kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_backends/sync.py", line 205, in connect_tcp
    with map_exceptions(exc_map):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/contextlib.py", line 158, in __exit__
    self.gen.throw(typ, value, traceback)
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_exceptions.py", line 14, in map_exceptions
    raise to_exc(exc) from exc
httpcore.ConnectError: [Errno -2] Name or service not known

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/openai/_base_client.py", line 877, in _request
    response = self._client.send(
               ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_client.py", line 915, in send
    response = self._send_handling_auth(
               ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_client.py", line 943, in _send_handling_auth
    response = self._send_handling_redirects(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_client.py", line 980, in _send_handling_redirects
    response = self._send_single_request(request)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_client.py", line 1016, in _send_single_request
    response = transport.handle_request(request)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 230, in handle_request
    with map_httpcore_exceptions():
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/contextlib.py", line 158, in __exit__
    self.gen.throw(typ, value, traceback)
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 84, in map_httpcore_exceptions
    raise mapped_exc(message) from exc
httpx.ConnectError: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_exceptions.py", line 10, in map_exceptions
    yield
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_backends/sync.py", line 206, in connect_tcp
    sock = socket.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/socket.py", line 827, in create_connection
    for res in getaddrinfo(host, port, 0, SOCK_STREAM):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/socket.py", line 962, in getaddrinfo
    for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno -2] Name or service not known

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 67, in map_httpcore_exceptions
    yield
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpx/_transports/default.py", line 231, in handle_request
    resp = self._pool.handle_request(req)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection_pool.py", line 268, in handle_request
    raise exc
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection_pool.py", line 251, in handle_request
    response = connection.handle_request(request)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 99, in handle_request
    raise exc
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 76, in handle_request
    stream = self._connect(request)
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_sync/connection.py", line 124, in _connect
    stream = self._network_backend.connect_tcp(**kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_backends/sync.py", line 205, in connect_tcp
    with map_exceptions(exc_map):
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-python3.11/lib/python3.11/contextlib.py", line 158, in __exit__
    self.gen.throw(typ, value, traceback)
  File "/usr/lib/wingpro10/bin/__os__/linux-x64/runtime-pip-openai-py3.11/lib/python3.11/site-packages/httpcore/_exceptions.py", line 14, in map_exceptions
    raise to_exc(exc) from exc
httpcore.ConnectError: [Errno -2] Name or service not known

The above exception was the direct cause of the following exception:

Traceback (most recent call ...
(more)
hongyi-zhao's avatar
547
hongyi-zhao
asked 2024-02-26 07:05:01 -0600
Wingware Support's avatar
4.2k
Wingware Support
updated 2024-02-26 07:40:54 -0600
edit flag offensive 0 remove flag close merge delete

Comments

As far as I can tell, it's failing to look up the website address used by OpenAI to implement its API. Are you able to bring up the site platform.openai.com in a web browser on your system?

Wingware Support's avatar Wingware Support (2024-02-26 07:40:39 -0600) edit
add a comment see more comments