Skip to content

Compile-time issues when upgrading to 4.1.2 #474

Description

@ssynix

Description

I'm trying to upgrade java-client 3.4.1 to 4.1.2.

Details

Our framework is built on top of Selenium and Appium's java-client. With the recent update, a simplified version of our interfaces below is failing to compile. I've tried multiple modifications to our code with no result, especially since I don't understand why the error is happening.

Code To Reproduce Issue

I've managed to narrow down the problem to this set of interfaces on Ideone. I believe this change is what is causing the issue for us.

  • For some reason, if we continue to extend MobileDriver without a generic parameter, the compiler is not able to override execute. This completely baffles me...
  • If I extend MobileDriver<WebElement> or change all our interfaces to generic (IFrameworkMobileDriver<T extends WebElement> extends MobileDriver<T>), the Java compiler pulls two versions of FindsByXPath into the our class with what it thinks are non-covariant return types (List<T> and List<WebElement> are not covariant?).

Any idea what I'm missing here?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions