Skip to content

java.util.HashMap cannot be cast to org.openqa.selenium.WebElement #826

@telangn

Description

@telangn

Description

@SrinivasanTarget @mykola-mokhnach @TikhomirovSergey @jlipps
@saikrishna321

Once appium starts up and begins to find and use element id's in the mobile app, an error is thrown:

org.openqa.selenium.WebDriverException: Returned value cannot be converted to WebElement: {ELEMENT=1}
Caused by: java.lang.ClassCastException: java.util.HashMap cannot be cast to org.openqa.selenium.WebElement

Appium Log files: https://gist.github.com/telangn

Environment

Ubuntu 16 OS

<dependencies>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>3.8.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.seleniumhq.selenium</groupId>
			<artifactId>selenium-java</artifactId>
			<version>3.4.0</version>
		</dependency>
		<dependency>
			<groupId>io.appium</groupId>
			<artifactId>java-client</artifactId>
			<version>6.0.0-BETA2</version>
		</dependency>
		<dependency>
			<groupId>info.cukes</groupId>
			<artifactId>cucumber-java</artifactId>
			<version>1.2.5</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>info.cukes</groupId>
			<artifactId>cucumber-picocontainer</artifactId>
			<version>1.2.5</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>info.cukes</groupId>
			<artifactId>cucumber-junit</artifactId>
			<version>1.2.5</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

Details

GIST for appium log files:

https://gist.github.com/telangn

Link to Appium logs

https://gist.github.com/telangn

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions