"Socket hang up" when starting Appium server using 'Espresso'

Trying to start the Appium server using ‘Espresso’ with below configurations:

“app”: “/Users/xyz/Downloads/app-debug.apk”,
“platformName”: “Android”,
“deviceName”: “emulator-5554”,
“automationName”: “espresso”,
“fullReset”: “true”,
“forceEspressoRebuild”: “true”

Exception received as below:

A new session could not be created. Details: An unknown server-side error occurred while processing the command. Original error: Could not proxy command to the remote server. Original error: socket hang up.

appium-server-logs.txt (27.6 KB)

Appium version: 1.23.0-beta.0 / 1.21.0-1

Here’s the error you are getting:

java.lang.NoSuchMethodError: No static method lifecycleEventObserver(Ljava/lang/Object;)Landroidx/lifecycle/LifecycleEventObserver; in class Landroidx/lifecycle/Lifecycling; or its super classes (declaration of ‘androidx.lifecycle.Lifecycling’ appears in /data/app/io.appium.espressoserver.test-z4Zirf10mrYG1Q9H2t7VhQ==/base.apk)

The closest thing I can find is this:

You don’t give any details on your setup but the discussion suggests it could be a bad Gradle entry.

1 Like