Mobile Device Connection Step by Step Guide

i am using Appium 1.20.2

1.20.x is broken for MobileAutomation activities. Try 1.21 or anything older between 1.15 - 1.19.

i downgraded to 1.15.0 . still not able to connect . Getting below error.

A session is either terminated or not started

Thank you very much , i was able to connect . i had given time out , which i removed and it worked :slight_smile:

@phaserescu Hi Cristian,

I was facing the issue for appium 1.20.2 now i downgrade to 1.15.1. but now it is keep connecting. not showing any logs or error. can you please tell me where i can see the actual logs like we can see in appium desktop app.

I’m not sure if in this state the logs are available in MDM (DEBUG LOG section). If you manage your appium server, you should see the logs in the console or you can even start appium using the Appium Desktop App and see the logs there.

I tried to see the logs in desktop app, but problem is it is starting the 1.20.2 server there… and showing same issue.

So how do you start the 1.15 appium then?

Through cmd

so your logs should be on the console, in the cmd window you start appium.

These are the logs in attached fappium-server-logs.txt (29.3 KB) ile.

@phaserescu It installed the file in emulator app but connection got terminated.
Here it is getting failed it seems:( attached are the full logs)appium-server-logs.txt (29.3 KB)
[WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8200/wd/hub/session] with body: {“capabilities”:{“firstMatch”:[{“platform”:“LINUX”,“webStorageEnabled”:false,“takesScreenshot”:true,“javascriptEnabled”:true,“databaseEnabled”:false,“networkConnectionEnabled”:true,“locationContextEnabled”:false,“warnings”:{},“desired”:{“platformName”:“Android”,“platformVersion”:“11.0”,“deviceName”:“emulator-5554”,“newCommandTimeout”:300,“shouldUseCompactResponses”:false,“elementResponseAttributes”:“rect”,“autoWebview”:false,“automationName”:“UiAutomator2”,“nativeWebScreenshot”:true,“app”:“https://uipathtestappsto.blob.core.windows.net/testapps/TheApp.apk"},“platformName”:“Android”,“platformVersion”:“11.0”,“deviceName”:“emulator-5554”,“newCommandTimeout”:300,“shouldUseCompactResponses”:false,“elementResponseAttributes”:“rect”,“autoWebview”:false,“automationName”:“UiAutomator2”,“nativeWebScreenshot”:true,“app”:“https://uipathtestappsto.blob.core.windows.net/testapps/TheApp.apk”,“deviceUDID”:“emulator-5554”,“appPackage”:“io.cloudgrey.the_app”}],"alwaysMatch”:{}}}

[WD Proxy] Got response with status 500: {“sessionId”:null,“value”:{“error”:“session not created”,“message”:“io.appium.uiautomator2.common.exceptions.NoSuchDriverException: A session is either terminated or not started”,“stacktrace”:"io.appium.uiautomator2.common.exceptions.SessionNotCreatedException: io.appium.uiautomator2.common.exceptions.NoSuchDriverException: A session is either terminated or not started\n\tat io.appium.uiautomator2.handler.NewSession.safeHandle(NewSession.java:57)\n\tat io.appium.uiautomator2.handler.request.SafeRequestHandler.handle(SafeRequestHandler.java:41)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleRequest(AppiumServlet.java:261)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleHttpRequest(AppiumServlet.java:255)\n\tat io.appium.uiautomator2.http.ServerHandler.channelRead(ServerHandler.java:68)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerCont…

[W3C] Matched W3C error code ‘session not created’ to SessionNotCreatedError

This is appium version

Here is configuration:

Note: It is working fine with any cloud based emulator saucelabs, Issue with local appium server

I’m not sure, what’s going on. You can also see the device logs issuing adb logcat to see if something helpful is written there. Also downloading the app and manually installing it with adb install .../path_to/app.apk and then starting the app on device to make sure it works on your emulator.

Hello, I am facing an error while starting an application in Uipath mobile Device manager. The error is " A session is either terminated or not started(session not created) ", All components are running and I successfully connected my device to Appium but when I trying to connect using the mobile device manager my Appium automatically disconnect from my device.

Hi Rahil, I am also facing the same issue. Could u please show where to give timeout. Screenshot is appreciated.

Thanks
Sumesh

Thanks,
updating Appium solved my problem


getting the error while installing the platform tool command in cmd prompt.
i have used the ApI level 30 because my mobile device is android version 11 so
command - sdkmanager “platform-tools” “platforms;android-30”

i am getting this screen while connecting my physical device with uipath

any help will be deeply appreciated

Look in the Appium logs to see if the session started or not. It might be that the session start returned an error for some reason but MDM didn’t picked up on that.

Hi @phaserescu i am attaching all the screen plz help me

application is opening in mobile but not in uipath.

i am trying mobile automation for the first time

screenshots:

image

image