-
-
Notifications
You must be signed in to change notification settings - Fork 8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue when casting decorated WebDrivers to RemoteWebDriver or JavascriptExecutor #9416
Comments
Thank you for sharing the details. I was able to reproduce the issue. |
Till the fix is in place, you can leverage the RemoteDriver object directly to get the session id. |
I have tried casting to JavascriptExecutor and it works as expected. No class cast exception is seen. If you faced any other error, please provide details for the same. |
The issue with the JavascriptExecutor seems to only happen when using a WebElement as a parameter. I am not sure how related the issues are other than they are caused by the decorator. Should i open another case?
|
This is how I have implemented RemoteFiringWebdriver, it is working fine up to Beta 1
|
Thank you for providing the samples, especially the JavascriptExecutor code sample. Appreciate it. |
🐛 Bug Report
In Selenium Java Since EventFiringWebDriver got deprecated in Beta 2 I changed my implementation to envelop my remoteWebDriver into to a decorated Webdriver using EventFiringDecorator. But i am having trouble whenever i have to cast it as a JavascriptExecutor or back to a remotewebdriver to access some values.
I get the following error:
To Reproduce
Expected behavior
object type is changed
Test script or set of commands reproducing this issue
Environment
OS: windows 10
Browser: firefox
Browser version: 86.0
Browser Driver version: GeckoDriver 0.29
Language Bindings version: java 4 beta 3
Selenium Grid version (if applicable): java 4 beta 3
The text was updated successfully, but these errors were encountered: