Good afternoon, I'm new to Selenium, and in general in programming. For personal use, I decided to make an automatic calculator for converting different currencies through Selenium. I was able to parse data from a couple of sites, but with a Visa site https://www.visa.com.my/support/consumer/travel-support/exchange-rate-calculator.html a special story. If you look through Chrome at the original code of the page, it is impossible to find the fields for entering currency and the rest there. But through developer mode, after loading javascript, the id of the currency input field #input_amount_paid
is visible in the debugging window, but again, even in developer mode, this selector does not search for the desired field. Please tell me how to find and fill in these fields?
https://i.stack.imgur.com/i2w2z.jpg
My code:
from fixture import get_browser
from locators import VisaLocators
import time
browser = next(get_browser())
browser.get(VisaLocators.LINK)
browser.find_element(*VisaLocators.COOKIES).click() # By.CSS_SELECTOR, '.wscrOk2:nth-child(2)'
time.sleep(1)
s = browser.find_element(*VisaLocators.AMOUNT) # By.ID, 'input_amount_paid'
print(s.is_displayed())
I tried to set up expectations, hover the mouse cursor over the calculator section and click on it, via WebDriverWait(browser, 5).until(EC.element_to_be_clickable((By.ID , "...")))
, but none of this solves the problem.