Questions tagged [selenium-webdriver]

Selenium WebDriver offers a versatile WebDriver API that allows developers to manipulate web browsers using various programming languages. Make sure to include a tag for the specific programming language you are utilizing.

Interference from Modal Overlay Disrupts functionality of other Links on Shared Page

My primary webpage consists of multiple links, including one that triggers a modal when clicked on. This modal opens on top of the main page, allowing me to compare expected and actual links. However, I encounter difficulty in comparing the rest of the lin ...

The for loop in Selenium WebDriver seems to be malfunctioning

I am encountering an issue with my page where I need to input scores for 16 different rows that are automatically generated. When I try to insert scores into each row using a for loop, the code works fine for just one row but fails when I attempt to run it ...

Having difficulty retrieving the alert text with selenium webdriver

I am currently facing an issue with verifying and dismissing alert text in my code. Despite following the steps to verify the alert text, I encountered failure. WebDriverWait wait = new WebDriverWait(driver, 10); wait.until(ExpectedConditions. ...

Discovering changing text on a website using Python's Selenium WebDriver

Website myList = ['Artik'] How do I verify if the content of myList is visible on the mentioned website? <span class="ipo-TeamStack_TeamWrapper">Artik<span> This specific webelement showcases 'Artik' in the given websi ...

What factors should be considered when selecting a suitable web scraper according to the type of content?

When selecting a scraper for a specific URL, I often encounter issues with BeautifulSoup not being able to scrape JavaScript protected pages. In these cases, I resort to using Selenium instead of BeautifulSoup. What I am interested in is how to determine ...

Shut down Chrome Web Driver when closing the Windows Form

I have a simple query that I've been struggling to find an answer for. Every time I try to close my Windows Form with the Selenium Chrome Web driver running, it shuts down the application but leaves the Chrome console and browser open. Is there a way ...

The error message "ValueError: invalid literal for int() with base 10: ''" keeps popping up while working with Selenium

After numerous attempts to scrape the website, I am faced with the challenge of not being able to locate the text in my pages indexing variable. Even though the pagination length is displayed correctly, indicating that the desired element has been found, t ...

I am trying to access an established profile on Chrome in order to navigate to a specific website, but I am encountering an issue with Chrome crashing and displaying error

An issue has been identified: The process started from the location C:Program FilesGoogleChromeApplicationchrome.exe is no longer running, leading ChromeDriver to assume that Chrome has crashed. Below is a code snippet: from selenium import webdriver ...

Experiencing challenges when using Selenium script on Firefox browser

Details Firefox version: 45.0.2 Selenium: selenium-java-2.53.1 (experimented with selenium-java-3.0.0-beta2 too) Script package Selenium_Practice; import java.util.concurrent.TimeUnit; import org.openqa.selenium.By; import org.openqa.selenium.WebDri ...

What are alternative ways to interact with a button inside a div element without relying on xpath for clicking?

My friend was asked this interview question that I am not sure about the answer. Can anyone help me out? Question: "How do you interact with a button that is within a div tag without using XPath?" Thank you, Mahesh ...

Issue encountered with Winiumdriver due to WebDriver exception

Recently, I started familiarizing myself with Winium tool and encountered an issue when running the code below: public class CalcDemo { public static void main(String[] args) throws MalformedURLException { DesktopOptions options=new DesktopO ...

Navigating through WebTables with a Horizontal Scroll Bar using Selenium

I am tasked with automating a WebTable that is embedded in the WebPage. The table contains numerous fields, causing it to have its own horizontal scrollbar separate from the rest of the WebPage. As a result, when attempting to interact or click on elements ...

I am attempting to utilize the webdriver feature within the selenium module, but I am consistently encountering an error regardless of my efforts

I am encountering difficulties using webdriver.Chrome in a project I am working on. Despite installing the correct version of Chrome, I keep getting this error. I'm lost and unsure how to proceed. Can anyone provide insight into what might be causing thi ...

Finding the element and extracting its text value

Below is the HTML code: <span> <b>Order number:</b> </span> <span>A36HASJH</span> The value within the span element, A36HASJH, is dynamic and changes with each order. How can I identify this element and store it as a s ...

Discovering the optimum settings for Firefox and Chrome with selenium-jupiter

Is it possible to run Selenium tests with different options for Firefox and Chrome? I have tried setting the options for both browsers, but it doesn't seem to work. Running the same tests with both browsers is feasible, as well as setting options for ...

When attempting to run tests with Chromedriver and Maven, a java.lang.NoSuchMethodError occurs with com.google.common.collect.ImmutableMap

Just starting out with selenium tests and currently following some tutorials on maven via YouTube. Today, I experimented with a few codes which worked fine until I encountered an "Access Denied" message while trying to search for a product on a store page ...

XPATH did not locate any elements in the document

Trying to extract specific text from an element within a table using the XPATH below: /html/body/form[2]/table/tbody/tr/td/table/tbody/tr[2]/td[7]/input attempting to do so with the following code: driver.maximize_window() # Maximize window driver.implici ...

Encountering a glitch while attempting to execute my test on webdriverio

Lately, I've encountered an issue while attempting to execute my webdriverio tests following an upgrade of my node version. The error message that now pops up is: 2022-01-11T12:45:05.628Z DEBUG @wdio/config:utils: Couldn't find ts-node package, n ...

Ways to confirm the presence of a browser using Selenium WebDriver

Currently, I am utilizing webdriver to open a Firefox browser and sequentially provide a URL to it using a spreadsheet that contains 5 URLs in various cells of column 1. In the event that I manually close the Firefox browser after two URLs have been open ...

Unable to Establish Connection Between Selenium Grid 2 Node and Hub

My computer has a local IP address of 192.168.1.x running Windows 7. Additionally, I have set up a VM with NAT IP 10.0.2.15 and a host-only IP of 192.168.70.64 also running Windows 7. The setup for my hub is quite simple: java -jar selenium-server-standal ...

Locate an original identifier using Selenium WebDriver

In search of a distinctive identifier for the "update profile picture button" on my Facebook account to utilize it in automation testing with Selenium WebDriver and Java. I attempted driver.findElement(By.className("_156p")).click();, but unfortunately, i ...

We are unable to start the session: The current ChromeDriver version is only compatible with Chrome version 79 and higher with Oct

Whenever I attempt to execute the "ng e2e" command with Octopus using the specified configuration, I consistently encounter the following error: [07:20:37] E/launcher - session not created: This version of ChromeDriver only supports Chrome version 79 (D ...

Getting elements from a table in Selenium Web Driver in JAVA is a common task for automating

Seeking ways to pinpoint Elements within the page. A table is present with numerous rows containing multiple Inputs. How can I retrieve Input from the various table rows? Below is my Java class definition: public class Setting extends Page { /**L ...

Issue with clicking the OK button in Selenium WebDriver using Java due to the presence of a span tag within the button tag

This is the HTML code snippet that I am working with: <div id="sieb-ui-popup-mvg-selected" class="AppletStylePopup"> <form onsubmit="return false;" action="/ecom_enu/start.swe" method="post" name="SWEForm4_0"> <div class="siebui ...

Upon running the Python Selenium script, Google Chrome will shut down automatically

I was testing this code and noticed that it runs without any errors, but for some reason it automatically closes Google Chrome after searching for w3schools. from selenium import webdriver from selenium.webdriver.common.keys import Keys driver = webdri ...

Uncover concealed email addresses on a webpage

On this website , I am trying to extract the email. I attempted using requests and Beautifulsoup without success. I also wrote this code utilizing selenium, but it did not work: from selenium import webdriver url = "https://aiwa.ae/company/arad-bui ...

What is the best way to locate and interact with this button using Python and Selenium?

The button we're looking for is labeled as the "View All Suggestions" Button. Therefore, a line of code should be written like this: browser.find_element_by_css_selector("something here").click() Remember, it doesn't necessarily have to be done by css. ...

Developing a unified driver that can navigate through various platforms with the help of proxy servers

After writing a Python script using Selenium and proxies to extract titles from various sites, I discovered that my current approach involves creating separate browser instances for each site. However, my primary objective is to utilize the same browser wi ...

Tips on obtaining the total element count within a specific div using Selenium

I am currently working on retrieving the count of search results when using the MakeMyTrip application to search for flights from Hyderabad to Bangalore. While I have successfully managed to extract the text, I am now looking for a way to confirm the numbe ...

I am looking for assistance with a Python web-scraping issue. I need help with scraping URLs from a webpage that has partially hidden pagination numbers. Can you lend a hand?

Looking to extract the URLs of each page from the pagination on a specific site located at . The challenge lies in the fact that not all page URLs are displayed simultaneously. When attempting to scrape using the provided link, only page-1, page-14, page- ...

Is it possible to translate Selenium IDE test scripts to Selenium WebDriver tests using Java programming language?

When recording my tests with Ghost inspector, I can export them in Selenium IDE format. Can these exported tests be used to write future Selenium web driver tests in Java? The format of the exported tests appears as follows: Navigation waitForPageToLoad ...

Utilize VBA-Selenium to export table data into separate Excel sheets

My current task involves extracting information from a website in tabular format based on specific keywords. Below are the keywords and the sample website: apple LG Samsung Nokia Website = www.wikipedia.com I have organized the keywords in Sheet 1 and th ...

You're unable to create an object of the type Select in Selenium WebDriver

I am attempting to create a test scenario where I need to choose multiple options from a multi-select drop-down menu. I have tried using the Select class but I encountered an error when trying to instantiate it. The error message I received is: "Cannot in ...

Utilize.send_keys(Keys.ENTER) for triggering an action in Python

Hey there, I'm a bit lost on where to post this, but I really need some guidance on how to make my code trigger the "ENTER" key using a keyboard input. from selenium import webdriver from selenium.webdriver.common.keys import Keys driver = webdrive ...

Error: Unable to initiate session: Although some devices were detected, they are not accessible:

Seeking to automate a Web app on iOS Safari for end-to-end testing. Although the following code was successful on an emulator in iOS 17 beta, it appears to not be functioning on a real device (iPhone 12, iOS 16.6). Code snippet for test: const fs = re ...

transferring files without a user interface

Looking for a solution to upload a file by clicking on an element: <a class="gray_box" href="#">Choose world folder<span>Select the world folder, we'll do the rest</span></a> The issue arises when the file manag ...

Tips for arranging a draggable list in Selenium

Here is a link for practicing sorting: I attempted the sorting with the following code: Actions action = new Actions(driver); List<WebElement> elements = driver.findElements(By.xpath("//*[@id="demo-tabpane-list"]/div/div")); fo ...

Unable to interact with cookies using Python's selenium package

My current project involves using Python, Selenium, and PhantomJS to access a webpage. After getting the page with driver.get and logging in, I received a notification that cookies needed to be enabled. In an attempt to access these cookies, I implemented ...

What are the best practices for managing certificates with Selenium?

I am currently utilizing Selenium to initiate a browser. What is the best approach for handling webpages (URLs) that prompt the browser to accept or deny a certificate? In the case of Firefox, I sometimes encounter websites that require me to accept their ...

Selenium - Warning: Unable to interact with element

Requirement: I need to update fields on a URL and click a button using Selenium. (See screenshot of webpage & HTML details below) Problem: An error is being returned as displayed below Error Message: Exception in thread "main" org.openqa.selenium.Elemen ...

Error in main thread: a.tagName.toUpperCase is not a function in JavascriptException

I am encountering an issue while trying to send values to this specific XPath. The error message above keeps appearing and I am unable to interact with that particular element. At times, when dealing with the same element, I receive an error stating eleme ...

A pair of identical dynamic drop-down menus selected using Selenium WebDriver technology

I am facing an issue with two dynamic drop down lists that are quite similar; I am encountering difficulty in selecting options from the second drop down list. Provided below is the HTML code snippet: <div id="list" class="x-list"> <div id="list- ...

Discover the elements that possess the ::after pseudo-element

I'm looking to extract specific labels from a list of labels. <div> <label class="search-reusables__value-label"> ::before <p class="display-flex">...</p> </label> <label class=" ...

Having trouble importing Selenium in my VSCode environment, despite having both Python and pip successfully installed

Despite having Python and pip installed correctly, I am encountering an error when trying to import selenium. Both the command prompt and VSCode acknowledge that Python is installed, yet the error persists. I am unsure of what step I am missing. Can anyo ...

Exploring techniques for retrieving hyperlinks from table cells using Selenium in C#

<tr role="row" class="odd"> <td class="sorting_1">Abrar</td> <td>1571</td> <td>Out</td> <td>No</td> <td>ALL</td> <td>Deskflex</td> <td> <a ...

How can I implement proxy authentication in ChromeDriver with Selenium and Java?

My current dilemma involves trying to launch Chrome with an authenticated proxy connection. I have all the necessary information: the proxy IP, port, username, and password. However, I need to figure out how to establish a connection with this proxy using ...

When working with Selenium and Python, I am unable to successfully close a dialog box

Currently, I am utilizing Selenium to gather data. However, there is an issue that arises when a message window appears. This window serves as just a manual, and I would like to disable it. Despite attempting various methods such as using find element by i ...

Can HTML comments prevent Selenium from running?

Currently, I am attempting to scrape a website with the following layout: <div> <!----> <!----> <!----> <div class="block"> <h3 class="subtitle is-4"></h3> ... ... </d ...

The type 'WebDriver' from Selenium cannot be resolved, and the type 'FirefoxDriver' cannot be resolved as well. This is not a duplicate issue

My first experience using this forum has been quite frustrating. My questions keep getting deleted as duplicates, even though the suggested solutions are not working for me. The initial problem was caused by incorrect jars, but I believe I have the correct ...

Facing a Chromedriver malfunction on my Django application hosted on the DigitalOcean App Platform

I am currently working on a web application using Django and the App platform on DigitalOcean. I have integrated Selenium and Chromedriver into my app, and I was able to install Chromedriver using Python libraries such as chromedriver_binary via pip. Howev ...

Having difficulty selecting an element with Selenium in Java

I am encountering difficulties with retrieving and utilizing a Select element using @FindBy. Here is the markup: <td> <felt [control]="kontactTypeFC" [classes]="'hb-distNone'"> <label for="contactTypes" class="hb-label"& ...

Solving puzzle captchas with Selenium while facing a maximum of 5 tries

I have been extracting data from this website: When using selenium to access the site, I sometimes encounter a puzzle captcha that needs to be solved after clicking on the "I am not a robot" captcha checkbox. The challenge is that the site only allows the ...

How can I save variable values to a text file or Excel file using Cypress.io?

Is there a way to write the values of a variable on a Text or Excel sheet? I have a variable called tex that stores string values, and I want to output these values onto text files or an Excel sheet if possible. beforeEach(() => { cy.visit('https:/ ...

Hold off until the specified text appears in the text box

How can we use WebDriver to wait until text appears in a text field? I am dealing with a kendo text field where the values are fetched from a database, so there is a delay before they appear. I need to ensure the values have loaded before moving forward. ...

Unable to locate specific text using XPATH contains and text() function

Here's a challenge - I'm attempting to come up with an XPATH that targets the list element containing the text "This Is The Text You're Looking For". Unfortunately, my current attempt using li//[contains(text(), 'This Is The Text You're Looking For')]

Utilizing ProtractorJS to Extract Numbers from Text within an Element and Dynamically Adding it to an Xpath Expression

Situation My objective is to extract text from an element on a webpage, convert that extracted text into a number in string format, and then use it for an xpath query. The code snippet below illustrates this process: var bookingRefString = element(by.css ...

Out of the blue, Firefox is now unable to load custom fonts from the same website due to a CORS

Utilizing Selenium Webdriver within a Python script, I am able to retrieve websites from my webpage and convert them into PNG files: from selenium import webdriver from selenium.webdriver.firefox.options import Options from selenium.webdriver.support.ui im ...

Utilize the same web browser across numerous test scenarios in Katalon Studio

I've been on a quest to discover if there's a way to use the same browser for multiple test cases. The website I'm testing requires each login when the browser is opened. Is there a feature that would enable me to maintain the same browser session and sea ...

Selenium Python to obtain tooltip text

Currently, I am attempting to extract dynamic content that only appears when hovering over certain elements. Despite utilizing ActionChains from Selenium for mouse movement and hover actions, I have been unable to capture the desired text. The main issue ...

What is the process for establishing a class within PageObject framework?

As a beginner in Selenium, I am using IntelliJ along with Selenium WebDriver and Junit. My current challenge lies in setting up the TestBase class within the PageObject framework. Below is an excerpt of my TestBase class: import org.junit.After; import or ...

The dropdown menu is unfortunately unresponsive to Selenium's attempts to click on it

Currently, I am working on automating the scraping process for a specific webpage: The main challenge I am facing involves dealing with a dropdown menu: https://i.stack.imgur.com/BCO7y.jpg This is the code snippet related to that particular section: apa ...

Press the OK button on a popup window using Selenium

I'm trying to click on the "OK" button in a modal alert, but for some reason I can't seem to make it work. // Capturing alert message. String alertMessage= driver.findElement(By.className("modal-header")) .getText( ...

Selenium with Python can be used to perform right-click actions on web

I am currently having difficulty in figuring out the correct way to execute a right click. Below is an example of my code: click_Menu = driver.find_element_by_id("Menu") print(click_Menu.text) action.move_to_element(click_Menu) action.context_cl ...

The Java Selenium ChromeDriver experiences delays when loading a new page

I am currently working on a script that automates the login process on a website and performs certain actions. The code for logging in is as follows: WebDriver driver; JavascriptExecutor exec; String dni = "..."; String passwd = "..."; ...

Accessing the downloaded file from the browser footer using Capybara and Selenium

Can you advise me on how to open a downloaded file from the footer bar? I am working on creating tests for downloading a PDF in Chrome. I would like to be able to open the file and verify its contents as well. Thank you! ...

Implementing @BeforeSuite to run after setting up the webdriver instance in Arquillian

I am facing an issue with using @BeforeSuite after the instantiation of WebDriver in Arquillian. Below is an example: @RunAsClient public class GoogleTest extends Arquillian { @Drone private WebDriver driver; @ArquillianResource private ...

How can Selenium be used to identify an Internet Explorer browser extension?

Can Selenium be used to detect internet explorer browser plugins? For example, if I open a URL on IE and want to check for any installed plugins, is there a way to automate this with selenium? ...

Encountering a WebdriverException in C# Selenium when an element is not located

When using c# Selenium, I encountered an issue where the FindElement method was unable to locate an element on the page. Instead of throwing a NoSuchElementException as expected, it resulted in a WebDriverException. The Exception details are as follows: ...

Unable to input data into form text box using Selenium WebDriver

Hello, I have encountered an issue while using the way2sms website and trying to enter a mobile number in the send SMS screen with Selenium WebDriver. Here is the relevant HTML code: form id="smsFrm" name="smsFrm" method="post"> <input id="ssaction" ...

Entering a date in a disabled datepicker using Selenium

I am encountering an issue while trying to input my own chosen date as the datepicker is disabled. Whenever I click on the datepicker, it prompts me to select a specific date and even for changing the month, multiple clicks are required. This has left me f ...

Converting Windows Identifiers to Human-Readable Text with the Power of Selenium and Python

I am aware that in order to retrieve the corresponding IDs of the currently open windows, I utilize the following code snippet in Python: current_windows = driver.window_handles print(current_windows) Output (assuming there are 2 open windows): ['CDwindow ...

Converting an array of RGBA values to hexadecimal: A step-by-step guide

Click here for snapshot[Snapshot] I am working on extracting the background color of one of seven days and converting it to hexadecimal. The highlighted hours are automatically selected at midnight and displayed in purple. My goal is to identify these hi ...

Ways to iterate through child elements using the Selenium xpath method

I'm currently facing an issue while trying to extract names from reviews of a specific product. I am struggling with looping over each review block to retrieve the names nested within them. This is the code I have written so far: from bs4 import Beau ...

How can you traverse through CSS page numbers using Python?

Is there a way to create a loop that iterates through page numbers for aria-label? browser.find_element_by_css_selector('[aria-label="Page 1"').click() browser.find_element_by_css_selector('[aria-label="Page 2"').click() browser.find_el ...

How can I specifically extract data from certain columns in an HTML table using BeautifulSoup? Currently, my code is pulling data from every column

I need help extracting specific data from an HTML table. I want to extract the information from the columns with the text "Total" and the value "93" only, rather than extracting all column data as my current code does. For example, the current output is: ...