When I try to click on the reply button using selenium in craigslist.org It doesn't open anything, it just gives an error like "Error please try again later". If i'm opening the same craigslist's ad in google chrome instance it is running without problem. any idea?
Most of the websites don't allow remote applications like automation software(
webdriver) to render their pages.
webdriver accesses a user agent it specifies its presence by setting the
readonly attribute boolean webdriver = true. This is how the user agent will come to know if it is being controlled by a normal user or
You must also refrain from using these kind of public sites for practising selenium.
You are right; the error appears due to reCaptcha. Unfortunately, it is impossible to bypass this error by means of Selenium. I can offer the following options to solve the problem:
Try to add a special test-agent to the browser
ChromeOptions options = new ChromeOptions ();
options.addArguments ("- user-agent = ...");
Later on, you are to talk to the development team and ask them to add a handler for such a user-agent and remove reCaptcha for it.
- This variant is similar to the first one, but it presupposes the use of a certain cookie, i.e. at the very start, a special cookie is added. It is processed by the site and the site does not use reCaptcha.
- Try to use another browser instead of Chrome, for example IE.
Hope it helps!