ChatGPT icon indicating copy to clipboard operation
ChatGPT copied to clipboard

[Bug]: Max retries exceeded with url: /api/conversation

Open kevindany opened this issue 1 year ago • 7 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues and checked the recent builds/commits

What happened?

python3 -m revChatGPT.V1

Get error:

SSLError(e, request=request) requests.exceptions.SSLError: SOCKSHTTPSConnectionPool(host='bypass.duti.tech', port=443): Max retries exceeded with url: /api/conversation (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

Steps to reproduce the problem

  1. Install latest package 2.Run above command 3.Failed to get the response from openai

What should have happened?

Should get response from openai

Version where the problem happens

revChatGPT 3.3.4

What Python version are you running this with?

3.9.7

What is your operating system ?

No response

Command Line Arguments

python3 -m revChatGPT.V1

Console logs

Full trackback:
Traceback (most recent call last):
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/connectionpool.py", line 703, in urlopen
    httplib_response = self._make_request(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/connectionpool.py", line 386, in _make_request
    self._validate_conn(conn)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/connectionpool.py", line 1042, in _validate_conn
    conn.connect()
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/connection.py", line 414, in connect
    self.sock = ssl_wrap_socket(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/util/ssl_.py", line 449, in ssl_wrap_socket
    ssl_sock = _ssl_wrap_socket_impl(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/util/ssl_.py", line 493, in _ssl_wrap_socket_impl
    return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
  File "/Users/xx/opt/anaconda3/lib/python3.9/ssl.py", line 500, in wrap_socket
    return self.sslsocket_class._create(
  File "/Users/xx/opt/anaconda3/lib/python3.9/ssl.py", line 1040, in _create
    self.do_handshake()
  File "/Users/xx/opt/anaconda3/lib/python3.9/ssl.py", line 1309, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:1129)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/requests/adapters.py", line 489, in send
    resp = conn.urlopen(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/connectionpool.py", line 787, in urlopen
    retries = retries.increment(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/urllib3/util/retry.py", line 592, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: SOCKSHTTPSConnectionPool(host='bypass.duti.tech', port=443): Max retries exceeded with url: /api/conversation (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/xx/opt/anaconda3/lib/python3.9/runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/Users/xx/opt/anaconda3/lib/python3.9/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/revChatGPT/V1.py", line 1051, in <module>
    main(configure())
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/revChatGPT/V1.py", line 58, in wrapper
    out = func(*args, **kwargs)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/revChatGPT/V1.py", line 1029, in main
    for data in chatbot.ask(prompt):
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/revChatGPT/V1.py", line 503, in ask
    response = self.session.post(
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/requests/sessions.py", line 635, in post
    return self.request("POST", url, data=data, json=json, **kwargs)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/requests/sessions.py", line 587, in request
    resp = self.send(prep, **send_kwargs)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/requests/sessions.py", line 701, in send
    r = adapter.send(request, **kwargs)
  File "/Users/xx/opt/anaconda3/lib/python3.9/site-packages/requests/adapters.py", line 563, in send
    raise SSLError(e, request=request)
requests.exceptions.SSLError: SOCKSHTTPSConnectionPool(host='bypass.duti.tech', port=443): Max retries exceeded with url: /api/conversation (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1129)')))

Additional information

No response

kevindany avatar Mar 12 '23 03:03 kevindany

i also have same question

johnshuxian avatar Mar 12 '23 06:03 johnshuxian

me too,but if you rerun from begining could work!

skyance avatar Mar 12 '23 08:03 skyance

pip install revChatGPT --upgrade

xiachong404 avatar Mar 12 '23 12:03 xiachong404

i mean ,begin from the code about set API.insted of intall packege~

skyance avatar Mar 12 '23 12:03 skyance

me too: requests.exceptions.SSLError: HTTPSConnectionPool(host='openaipublic.blob.core.windows.net', port=443): Max retries exceeded with url: /encodings/cl100k_base.tiktoken (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:997)')))

daluzhongcaoyao avatar Mar 12 '23 15:03 daluzhongcaoyao

free version uses proxy and is expensive to keep the same so it is limited due to cost.

noseon avatar Mar 12 '23 17:03 noseon

Looks like a network issue on your ends. Cloudflare is blocked in random parts of China as well as some other places

acheong08 avatar Mar 13 '23 00:03 acheong08

This article may help you if you are using http-proxy: https://ywang-wnlo.github.io/posts/76f6af57.html

NFHr avatar Mar 13 '23 16:03 NFHr

This issue is stale because it has been open for 2 days with no activity.

acheong08 avatar Mar 16 '23 02:03 acheong08