Closed papb closed 3 years ago
If curl
fails, there's definitely something wrong with the webserver. I'm not surprised browsers work. They are extremely lenient and allow a lot of incorrect behavior.
Hi @sindresorhus, thanks for the reply! Still, in this case, I find particularly surprising that Got times out. If there is something wrong with the server but browsers manage to be lenient with the response, I would expect another error, not a timeout.
Do you have any idea on what exactly could Request be doing differently from Got here?
I've just done curl https://www.ansys.com
and I'm getting a timeout.
I'm pretty sure they have some anti-bot mechanism and it blocks the requests.
Describe the bug
Got is failing to get the following specific website: https://www.ansys.com
request
library also can fetch it, without any extra setup!However, to my surprise, the
wget
andcurl
commands also fail to fetch it. Maybe something is wrong with this particular website in a very weird way. But since Request can do it, I think Got should do it as well.I found a related question on StackOverflow, but reading it didn't help me.
Note: not sure if it matters, but I am at home, not behind a proxy (that I know of - unless my ISP uses one somehow). The websites http://www.amibehindaproxy.com/ and http://ipv4.amibehindaproxy.com/ also claim that I do not seem to be behind a proxy.
I also looked into Migrating from Request but couldn't see anything that might explain my situation.
Note: the same problem also happens with the HTTP version: http://www.ansys.com
Actual behavior
Expected behavior
Should fetch the page successfully.
Code to reproduce
Extra info
Behavior from other tools:
Tested with
nikolaik/python-nodejs:python3.9-nodejs14
Checklist