vsakkas / sydney.py

Python Client for Copilot (formerly named Bing Chat), also known as Sydney.
MIT License
239 stars 31 forks source link

"Solve CAPTCHA to continue" Issue. #166

Open sonugit0607 opened 1 month ago

sonugit0607 commented 1 month ago

I have been using Sydney since a while, and recently in the past week all of a sudden I'm facing "Solve CAPTCHA to continue" issue continuously, whether I clear my cookies and cache. Also tried adding the Copilot cookies in the code itself as mentioned in the Pypi Documentation still didn't work for me. Please help me with this issue, Thanks in advance.

Screenshot 2024-05-09 144346
sonugit0607 commented 1 month ago

@vsakkas have a look into it!, it would solve me a big problem if I get any solution. due to this one of my project is on hold🥲.

vsakkas commented 1 month ago

Hi @sonugit0607

Sorry, I have been inactive for quite some time now (been busy moving to another country!), but this seems quite important. I will try to take a look at all the open issues on the repo, including this one, in the next few days :)

sonugit0607 commented 1 month ago

thanks!

usun1997 commented 1 month ago

easy question. You need to manually go to copilot website and start one conversation. and then microsoft bing will verify your identity, after verification, you can use the python copilot.

sonugit0607 commented 1 month ago

tried multiple times, didn't work.

usun1997 commented 1 month ago

tried multiple times, didn't work.

It can’t be possible! First, ensure that the cookie you are using corresponds exactly to the Copilot account you are currently logged into. Sometimes, you might log into account A but use a cookie for account B, and your web browser has not yet updated to show that you are logged into account A. It can fool you. Secondly, the only reason the ‘Solve CAPTCHA to continue’ message appears is that Microsoft Bing sometimes activates a system check to confirm if you are a ‘human.’ This can interrupt the Python Bing chat. I simply go to the website, send a question to Bing AI, and a box appears stating that it is verifying something. After this process, I am good to go.

sonugit0607 commented 1 month ago

it's not happening in my case, I'm using the same accounts cookies to which I have logged in. and also I don't see any box appears saying "Verifying".

usun1997 commented 1 month ago

so you are able to manually chat with copilot in many rounds on the web, and there is no box comming out to let you click "confirmed" something like that? theoretically, if you can chat on the web then your python copilot is supposed to work. If you still encounter this issue, I think it is because you account is banned by microsoft for some reason (but I don't believe it). You can test it by creating a new account and see whether python copilot works again.

sonugit0607 commented 1 month ago

Actually it's my work profile, not personal.

vsakkas commented 1 month ago

Hi @sonugit0607 I haven't been able to reproduce this issue unfortunately. I've released a couple minor updates to the sydney package, so please update to the latest version (although I don't think that will change anything)

Besides that, it is possible that your account or IP address has been blocked. Can you reproduce this issue with a different account or with a different IP or on a different machine?

sonugit0607 commented 1 month ago

Hi @vsakkas In the same device I have tried with multiple accounts as well, getting same issue. Not sure what's causing this.

RexsyBima commented 1 month ago

yup, can confirm this, i got this weird solve captcha to continue even if i already try to change the cookies and everything

ammar-n-abbas commented 1 month ago

Similar issue faced by my team too

RexsyBima commented 1 month ago

Hey an update here, i manage to get it to working again by changing to other microsoft account, it seems they block my account for interacting with sydney py too many times, i hope the blocking is temporary

vsakkas commented 1 month ago

To summarize what I've read so far, here's a few things to try:

It is possible that either the IP or the machine have gotten blocked from high usage of the API.

Also, if you're using a proxy, keep in mind that currently proxy support is.. not the best. I will if I can do something about it during this weekend.

mizrits commented 3 weeks ago

I also encountered the same situation. But after updating the cookie value, it works again (without CAPTCHA)!

mrkami1 commented 6 days ago

I'm getting the same issue and I have tried changing the cookies and tried a different machine.

vsakkas commented 6 days ago

To summarize what I've read so far, here's a few things to try:

* Get new cookies

* Use a different account

* Use a different machine

* Use a different account **and** machine

It is possible that either the IP or the machine have gotten blocked from high usage of the API.

Also, if you're using a proxy, keep in mind that currently proxy support is.. not the best. I will if I can do something about it during this weekend.

Another thing that I didn't mention is that you need to send a message to Copilot on the website itself so that you can verify that you're a human. Usually this shows up on the first message, but after testing, it seems that lately it can also show up on the second message.

mrkami1 commented 6 days ago

I'm getting the same issue and I have tried changing the cookies and tried a different machine.

I've now gotten it to work. I was previously using the cookies from Firefox and now tried cookies from Edge and it works fine.

Luneye commented 1 day ago

Maybe the retrieved cookies from Firefox aren't working due to the user headers emulation in the constants.py file (the CREATE_HEADERS constant). I believe that if you change the CREATE_HEADERS constant with the same headers you used in the request to retrieve your cookies on Firefox, it may work!

I also confirm that the cookies retrieved using Edge or Chrome (since both are Chromium-based browsers) work with the current implementation of this project :)