Skip to content

fix: Fix Selenium 4.34.0+ compatibility #2298

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

Merged
merged 2 commits into from
Jun 2, 2025

Conversation

valfirst
Copy link
Collaborator

@valfirst valfirst commented Jun 2, 2025

Change list

  • ContextAware interface was removed from Selenium: SeleniumHQ/selenium@3c25c92. io.appium.java_client.remote.SupportsContextSwitching will be a replacement for the removed interface.

Closes #2296.

Types of changes

What types of changes are you proposing/introducing to Java client?

  • No changes in production code.
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Details

Note: new release will be required once new Selenium release is published.

@@ -39,8 +38,7 @@
import java.util.Map;
import java.util.Set;

public class EmptyWebDriver implements WebDriver, ContextAware,
JavascriptExecutor, HasCapabilities, TakesScreenshot {
public class EmptyWebDriver implements WebDriver, JavascriptExecutor, HasCapabilities, TakesScreenshot {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should it instead implement SupportsContextSwitching ?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed the corresponding methods, they were not used

@valfirst valfirst merged commit e98bf2d into appium:master Jun 2, 2025
7 checks passed
@valfirst valfirst deleted the fix-selenium-4-34-0-compatibility branch June 2, 2025 18:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Is there an replacement for org.openqa.selenium.ContextAware interface in Appium?
2 participants