+ 1

How to solve 405 error in python web scraping?

I was scraping a website and got 405 error. After searching a while I got to know that it's a good error that means the resource I'm looking for exists but I don't have access to it. The possible reason may be that I'm accessing it via python interpreter and not the browser. So now the question arises is how do I fake a website to feel it like browser is accessing it and not the Python.

23rd Sep 2020, 11:56 AM
Abhijeet Dhanwate
Abhijeet Dhanwate - avatar
7 Antworten
+ 3
Which site you are accessing??
23rd Sep 2020, 12:46 PM
AKSHAY🇮🇳
AKSHAY🇮🇳 - avatar
+ 3
coderAbhii Ok now share your code. So that I can see what data you want to fetch and where the problem is..
23rd Sep 2020, 12:52 PM
AKSHAY🇮🇳
AKSHAY🇮🇳 - avatar
+ 3
coderAbhii I can't find any link in that site that redirect me to a login page. You can try these methods: 1. Check your credentials. 2. Check that you have used correct method to send data. 3. Check if that forms requires any other credentials like token id. 4. Contact to that site and ask for help from them.
23rd Sep 2020, 1:57 PM
AKSHAY🇮🇳
AKSHAY🇮🇳 - avatar
+ 2
I'm accessing something which requires login access to the site. I have the credentials and I sent a post request to the site but it gives the status code 405. It won't be good to share the code due security reasons. I hope u understand
23rd Sep 2020, 12:54 PM
Abhijeet Dhanwate
Abhijeet Dhanwate - avatar
+ 2
Ok I understood...
23rd Sep 2020, 1:40 PM
AKSHAY🇮🇳
AKSHAY🇮🇳 - avatar
+ 1
Collpoll.com
23rd Sep 2020, 12:49 PM
Abhijeet Dhanwate
Abhijeet Dhanwate - avatar
+ 1
Okay sure! Thanks for the help
23rd Sep 2020, 1:58 PM
Abhijeet Dhanwate
Abhijeet Dhanwate - avatar