I have a problem with bypass Arkoselabs Funcaptcha with selenium on Twitter page.
I cant submit token because there is not any submit button.
When I try to paste token and just click random pictures I get wrong answer error.
I also tried to solve captchas by getting captcha picture and instructions, request something like 2captcha and click on images. It worked before, but now there is new type of captcha with arrows. When I did the same things I just get wrong answer from 2captcha.
Do you know what should I do?
c# code. Similar to this in Python
var captchaToken = "3084f4a302b176cd7.96368058|r=ap-southeast-1|guitextcolor=%23FDD531|......";
((IJavaScriptExecutor)chrome).ExecuteScript("parent.postMessage(JSON.stringify({eventId:'challenge-complete',payload:{sessionToken:'" + captchaToken + "'}}),'*')");
Related
I'm getting error about captcha based on url i am unable to see the captcha, is there any method to show the captcha. i want any suggestion to get that captcha visible and let my url run.
Unfortunately, it's not possible to display CAPTCHA on Postman. CAPTCHA is designed to prevent automated systems (like Postman) from accessing the API and is meant to be displayed and solved by a human. You'll need to manually access the API through a web browser to solve the CAPTCHA before making the API request.
Cant submit Captcha textfield in python selenium
Hello everyone,
I want to submit a textfield which is filled with the Code for Captcha, but I can't submit it.
This is the Error:
Exception has occurred: NoSuchElementException
Message: Unable to locate element: ./ancestor-or-self::form
enter image description here
This is my script(it works perfectly on other webpages):
sub = driver.find_element_by_class_name("g-recaptcha-response")
sub.submit()
have tried also a lot of other things, but nothing worked.
Here the HTML-Code:
enter image description here
The Textfield is that in the whole bottom.
I would be very happy, if someone can help me. Thank you for you time!
Ps: This is my first Question, so sorry, if I did something wrong. And I am not from the USA or England, so my English is a bit bad...
The reason this error occurs is that you are trying to find a specific element before it is rendered.
To put it simply, the web page is not ready yet, but it is a problem that occurs when you try to scrape information.
sub = driver.find_element_by_class_name("g-recaptcha-response")
sub.submit()
Edit it!
From official Selenium documentation:
CAPTCHA, short for Completely Automated Public Turing test to tell Computers and Humans Apart, is explicitly designed to prevent automation, so do not try!
What you could do instead is
Disable CAPTCHAs in your test environment
Add a hook to allow tests to bypass the CAPTCHA
I've just started using Selenium and I can successfully fill a form and click the submit button using the examples code, however I get an error message (which only appears written in the website after submitting, not an actual coding error) which says "There has been an error, try again".
It seems to me the website somehow knows I'm not filling the form manually, and it doesn't like that.
Is that the case ? What can I do in such cases ?
EDIT: This is the website with the form I'm trying to submit:
https://www.alitalia.com/it_it/special-pages/richiesta-rimborso-volo-cancellato.html
Using selenium I can browse through the entire website except for the login screen on a specific website. When I checked page source I see some js codes.
Using a normal chrome browser I can access the expected login screen. Can anyone help me to overcome this issue? Thanks in advance.
Chances are that the website is detecting that you are using a bot and is blocking you from accessing its login screen for that reason. I can't know for sure that this is the reason because I haven't seen your issue in person, but most good websites don't like having non-human users interact with their pages, and a login page is exactly the type of page that the website would block you from accessing.
You can try to change some things to make Selenium less detectable by the website, but it's quite difficult and inconsistent at best. You can find some more information about achieving this here, but I wouldn't expect too much.
I try to login a site automatically by selenium.
My script sometimes works smoothly but sometimes it does not send full-text of user name or passwork to relavant inputs so it then failed to login.
I try to insert implicitly_wait but it appears not to solve this problem totally.
I wonder if there is any function to require the webdriver to fullfill each of input before excecute another one in selenium.
Here is may attempt:
browserdriver.get(url)
#fill username
browserdriver.implicitly_wait(25)
psusername=browserdriver.find_element_by_xpath("//*[#class='form-group'][1]/input[#name='username']")
psusername.click()
psusername.send_keys("1234567890")
#fill password
browserdriver.implicitly_wait(25)
pspass=browserdriver.find_element_by_xpath("//*[#class='form-group'][2]/input[#name='password']")
pspass.click()
pspass.send_keys("abcdefgfk12345")
browserdriver.implicitly_wait(25)
pssubmit=browserdriver.find_element_by_xpath("//*[#class='login-btn']/button[#type='submit']")
pssubmit.click()
Pls, explain for me why I get stuck on this problem and how to solve it! thanks alot
EDIT1: I add the target site address: click here You should click on login words (Đăng nhập) on the top right screen to see the popup login pannel.
EDIT 2: Thank to guide of below comments, I try to add some code lines to force it to key individual letter and it appears to work well so I add solution here:
text_input="1234567890"
for i in text_input:
psusername.send_keys(i)
Use set attribute instead of sendkeys
here is the example code:
webdriver.executeScript("document.getElementById('elementID').setAttribute('value', '1234567890')");