AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Stack the states website4/10/2023 ![]() ![]() ![]() Linux is popular in part because it offers more flexibility and configuration options than some other operating systems. Today, it has an extensive worldwide user base that extends across industries. Linux: The operating system. Linux is a free and open source operating system (OS) that has been around since the mid-1990s.Each component contributes essential capabilities to the stack: Together, they provide a proven set of software for delivering high-performance web applications. Partial_url = search_string.replace(" ", "+") Search_string = "Kinderarzt Kanton Aargau" # Declare string to search for and encode it I used a different CSS selector and found it just fine. My guess is that the class you are using is changing regularly. Second, your "Wait for results to load" locator was not on my page. I think it can not find the object and there must be another way to identify the objects.įirst, you can skip several steps by just building the URL for google maps with the desired search string. PS: I have tried to increase the time for the webdriver, but that won't help. Results = wait.until(EC.visibility_of_all_elements_located((By.CSS_SELECTOR, "div > div > div > a"))) Wait.until(EC.element_to_be_clickable((By.XPATH, "//a"))).click() Search_box.send_keys("Kinderarzt Kanton Aargau") ![]() Search_box = driver.find_element(By.NAME, "q") Wait.until(EC.element_to_be_clickable((By.CSS_SELECTOR, "#L2AGLb > div"))).click() Here is the code that I have so far: from selenium import webdriverįrom import Byįrom import WebDriverWaitįrom import expected_conditions as EC Is there anything wrong with my code? I would like to extract the website URL of the results. I can see in the window that opens, that the results are fully loaded. This is where I get the error, as I am trying to wait for the results to load, but I always get a timeout. Search for random thing (in this example "pediatrician in Aargau").I am trying to search with python via Google Maps and I want to get the URL from the results. ![]()
0 Comments
Read More
Leave a Reply. |