diff options
author | H Lohaus <hlohaus@users.noreply.github.com> | 2024-04-11 03:36:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-11 03:36:12 +0200 |
commit | 4271fb9870fff99be2895216a839a9484aa5dbf3 (patch) | |
tree | 78a714c01fac85ed34856e9c295f9028efed576b /g4f/Provider/bing | |
parent | Merge pull request #1817 from hlohaus/bugfix (diff) | |
parent | Add ReplicateImage to provider list (diff) | |
download | gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar.gz gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar.bz2 gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar.lz gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar.xz gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.tar.zst gpt4free-4271fb9870fff99be2895216a839a9484aa5dbf3.zip |
Diffstat (limited to 'g4f/Provider/bing')
-rw-r--r-- | g4f/Provider/bing/conversation.py | 4 | ||||
-rw-r--r-- | g4f/Provider/bing/create_images.py | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/g4f/Provider/bing/conversation.py b/g4f/Provider/bing/conversation.py index e9cdfe31..ef48cd91 100644 --- a/g4f/Provider/bing/conversation.py +++ b/g4f/Provider/bing/conversation.py @@ -34,9 +34,9 @@ async def create_conversation(session: ClientSession, headers: dict, tone: str) Conversation: An instance representing the created conversation. """ if tone == "Copilot": - url = "https://copilot.microsoft.com/turing/conversation/create?bundleVersion=1.1634.3-nodesign2" + url = "https://copilot.microsoft.com/turing/conversation/create?bundleVersion=1.1686.0" else: - url = "https://www.bing.com/turing/conversation/create?bundleVersion=1.1626.1" + url = "https://www.bing.com/turing/conversation/create?bundleVersion=1.1686.0" async with session.get(url, headers=headers) as response: if response.status == 404: raise RateLimitError("Response 404: Do less requests and reuse conversations") diff --git a/g4f/Provider/bing/create_images.py b/g4f/Provider/bing/create_images.py index cb357708..44303c21 100644 --- a/g4f/Provider/bing/create_images.py +++ b/g4f/Provider/bing/create_images.py @@ -151,7 +151,7 @@ async def create_images(session: ClientSession, prompt: str, proxy: str = None, if response.status != 200: raise RuntimeError(f"Polling images faild. Code: {response.status}") text = await response.text() - if not text: + if not text or "GenerativeImagesStatusPage" in text: await asyncio.sleep(1) else: break |