mozilla / geckodriver

WebDriver for Firefox
https://firefox-source-docs.mozilla.org/testing/geckodriver/
Mozilla Public License 2.0
7.03k stars 1.51k forks source link

Exceptions When Switching Frames in Firefox 102.0 ESR with GeckoDriver v0.32 #2164

Closed OtiliaRegheni closed 3 months ago

OtiliaRegheni commented 4 months ago

System

When switching to a different frame on a webpage using Selenium WebDriver with Firefox 102.0 ESR and GeckoDriver v0.32, intermittent exceptions are encountered when attempting to interact with elements within the switched frame. Instead of receiving a TimeoutException or a relevant error indicating the frame is not ready, the following exceptions are thrown without a preceding indication of frame availability issues:

This behavior is inconsistent and complicates element interaction within frames, requiring a workaround that involves retrying the frame switch and element interaction.

This issue can be reproduced by following these steps:

1.Initiate a Selenium WebDriver session with Firefox 102.0 ESR using GeckoDriver v0.32. 2.Navigate to a webpage that contains multiple frames. 3.Switch to a new frame using the "ExpectedConditions.frameToBeAvailableAndSwitchToIt(frameBy)" condition. 4.Attempt to select an element within the new frame context.

Expected Behavior: After switching to a new frame, elements within that frame should be selectable without errors.

Actual Behavior: When attempting to select an element within a newly switched frame, exceptions are thrown intermittently:

whimboo commented 4 months ago

Firefox ESR 102 is no longer supported so please switch to the recent (ESR) release. Also you should update geckodriver accordingly. If it is still reproducible for you please attach a trace-level log from geckodriver. Also read more about reporting actionable bugs in our contribution guidelines. Thanks.

OtiliaRegheni commented 3 months ago

Hello. I will try with a latest version of Firefox ESR and gecko driver and came back with feedback regarding this. Thank you.

whimboo commented 3 months ago

Closing as incomplete because of a missing reply from the reporter, but happy to reopen if more details are provided, which demonstrate that this is an issue with geckodriver or Firefox.