I am working on selenium python tests. In my local machine(windows) and remote machine(ubuntu and in headless mode) tests run fine. But on Jenkins pipeline the tests are failing. On remote and jenkins, Selenium version is same 4.1.3. Firefox version is same 98.0.1.
The first test fails with error selenium.common.exceptions.ElementNotInteractableException: Message: Element <a href="/text/funct/num/"> could not be scrolled into view
The window location and size prints same values for in all (windows, remote ubuntu and jenkins) machines
print(browser.driver.get_window_size())
print(browser.driver.get_window_position())
Output is same:
{'width': 1366, 'height': 768}
{'x': 0, 'y': 0}
I am trying to understand the issue. How should I debug further.
I am looking for a universal solution for all the errors since I am facing errors in multiple tests.
I have tried setting windows size but it didn't help.
self.driver.set_window_size(1920, 1080)
I have printed the page source self.driver.page_source
and I see the element <a href="/text/funct/num/">
is present in html as <td><a href="/text/funct/num/"><i class="val"></i></a></td>