Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenaiAccount/OpenaiChat - ResponseStatusError: Response 403: OpenAI Bot detected #2493

Open
The2Alert opened this issue Dec 17, 2024 · 9 comments
Assignees
Labels
bug Something isn't working

Comments

@The2Alert
Copy link

Error

{
    "error": {
        "message": "ResponseStatusError: Response 403: OpenAI Bot detected"
    },
    "model": "gpt-4o",
    "provider": "OpenaiAccount"
}

Auth
https://github.com/xtekky/gpt4free?tab=readme-ov-file#har-file-for-openaichat-provider

@The2Alert The2Alert added the bug Something isn't working label Dec 17, 2024
@The2Alert
Copy link
Author

@xtekky @hlohaus

@hlohaus
Copy link
Collaborator

hlohaus commented Dec 17, 2024

Hey @The2Alert, tell me more about your system? Does it always not work, or just sometimes? Have you tried it with a proxy?

@The2Alert
Copy link
Author

@hlohaus It's always the same error. The proxy used is from froxy.com . The account for which the HAR file was created has a Plus subscription and is created via Google Chrome according to the instructions in the README. It would be great to make it possible to log in via localhost:7900 .

@hlohaus
Copy link
Collaborator

hlohaus commented Dec 18, 2024

@The2Alert
I have this issue, if i use nodriver on docker with chatgpt.com:

future: <Task finished name='Task-11' coro=<Listener.listener_loop() done, defined at /home/g4f/.local/lib/python3.12/site-packages/nodriver/core/connection.py:591> exception=TypeError("string indices must be integers, not 'str'")>
Traceback (most recent call last):
  File "/home/g4f/.local/lib/python3.12/site-packages/nodriver/core/connection.py", line 634, in listener_loop
    tx(**message)
  File "/home/g4f/.local/lib/python3.12/site-packages/nodriver/core/connection.py", line 116, in __call__
    self.__cdp_obj__.send(response["result"])
  File "/home/g4f/.local/lib/python3.12/site-packages/nodriver/cdp/network.py", line 2726, in get_cookies
    return [Cookie.from_json(i) for i in json['cookies']]
            ^^^^^^^^^^^^^^^^^^^
  File "/home/g4f/.local/lib/python3.12/site-packages/nodriver/cdp/network.py", line 1376, in from_json
    partition_key=CookiePartitionKey.from_json(json['partitionKey']) if json.get('partitionKey', None) is not None else None,
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/g4f/.local/lib/python3.12/site-packages/nodriver/cdp/network.py", line 1275, in from_json
    top_level_site=str(json['topLevelSite']),
                       ^^^^^^^^^^^^^^^^^^^^
TypeError: string indices must be integers, not 'str'

There is a issue with the nodriver version.
I have created a working fix.

@The2Alert
Copy link
Author

@hlohaus thanks you, unittest failed :)
When is the Docker build release?)

@woniuzfb
Copy link

It would be great to make it possible to log in via localhost:7900

sed -i '/supports_gpt_4 = True/i \\ needs_auth = True' /app/g4f/Provider/needs_auth/OpenaiChat.py

@hlohaus
Copy link
Collaborator

hlohaus commented Dec 19, 2024

@woniuzfb Try OpenaiAccount. It is OpenaiChat with Auth.

@The2Alert
Copy link
Author

@hlohaus o1 not found

Endpoint: /v1/models

@noVibe
Copy link

noVibe commented Dec 22, 2024

Hi! Got same error. Running docker

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants