Skip to content
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

[Maestro version, e.g. v1.30.4] - Exception in thread while running ui test #1304

Open
02gaurav opened this issue Aug 1, 2023 · 6 comments
Labels
bug Something isn't working

Comments

@02gaurav
Copy link

02gaurav commented Aug 1, 2023

Describe the bug
Exception while clicking on some button, its asserting visibility correctly. Also, navigation is fine on tapping button. But after tapping on the button got this exception and remaining test cases got stuck.
Exception in thread "pool-4-thread-1" java.io.IOException: Command failed (tcp:7001): closed
at dadb.adbserver.AdbServer.send$dadb(AdbServer.kt:99)
at dadb.adbserver.AdbServerDadb.open(AdbServer.kt:138)
at dadb.forwarding.TcpForwarder.handleForwarding$lambda-1(TcpForwarder.kt:64)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:630)
at java.base/java.lang.Thread.run(Thread.java:831)

Expected behavior
There should not be any exceptions and test cases should not stuck.

Environment information (please complete the following information):

  • Maestro version: [1.30.4]
  • Platform: [Android 10]
  • Framework: [Native Android]
  • Device model and OS version: Android Redmi 9A based on Android 10
  • Host: Mac M1 chip
@02gaurav 02gaurav added the bug Something isn't working label Aug 1, 2023
@kojofosu
Copy link

kojofosu commented Aug 3, 2023

Experiencing this as well

Error: Exception in thread "pool-4-thread-1" java.io.IOException: Command failed (tcp:7001): closed
	at dadb.adbserver.AdbServer.send$dadb(AdbServer.kt:99)
	at dadb.adbserver.AdbServerDadb.open(AdbServer.kt:138)
	at dadb.forwarding.TcpForwarder.handleForwarding$lambda-1(TcpForwarder.kt:64)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)

@02gaurav
Copy link
Author

02gaurav commented Aug 3, 2023

@kojofosu If you will try Android 12 it is working fine.

@kojofosu
Copy link

kojofosu commented Aug 3, 2023

@02gaurav Thank you so much ..i did not get that error after trying with android 12 ....but hopefully we get to know why it failed with android 10 in the future..thanks for your response

@DavidREntwistle
Copy link

DavidREntwistle commented Aug 30, 2023

I'm experiencing this same issue on Maestro version 1.31.0 when running most Android 10 devices:

Exception in thread "pool-4-thread-1" java.io.IOException: Command failed (tcp:7001): closed
        at dadb.adbserver.AdbServer.send$dadb(AdbServer.kt:99)
        at dadb.adbserver.AdbServerDadb.open(AdbServer.kt:138)
        at dadb.forwarding.TcpForwarder.handleForwarding$lambda-1(TcpForwarder.kt:64)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
        at java.base/java.lang.Thread.run(Thread.java:833)
^C
Exception in thread "Thread-1" java.util.concurrent.TimeoutException: Couldn't close Maestro Android driver due to gRPC timeout
        at maestro.drivers.AndroidDriver.close(AndroidDriver.kt:166)
        at maestro.Maestro.close(Maestro.kt:462)
        at maestro.cli.session.MaestroSessionManager$MaestroSession.close(MaestroSessionManager.kt:332)
        at maestro.cli.session.MaestroSessionManager$newSession$1$1.invoke(MaestroSessionManager.kt:94)
        at maestro.cli.session.MaestroSessionManager$newSession$1$1.invoke(MaestroSessionManager.kt:88)
        at maestro.cli.db.KeyValueStore.withExclusiveLock(KeyValueStore.kt:37)
        at maestro.cli.session.SessionStore.withExclusiveLock(SessionStore.kt:74)
        at maestro.cli.session.MaestroSessionManager$newSession$1.invoke(MaestroSessionManager.kt:88)
        at maestro.cli.session.MaestroSessionManager$newSession$1.invoke(MaestroSessionManager.kt:87)
        at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:30)

The second exception above occurs when I Ctrl+C after the first exception stops the flows from continuing.

Environment information:
Maestro version: [1.31.0]
Platform: [Android 10]
Framework: [Native Android]
Device model and OS version: [Lenovo TB-X606F (Lenovo Tab M10 FHD Plus Tablet)]
Host: MacBook Pro M2 Max - Ventura 13.5.1

Edit:
Raised recent issue here:
#1525

@FilDevTronic
Copy link

Still occurring on 1.32.0

@grpicanco
Copy link

2023-11-08_11-18

Environment information:

Maestro version: 1.34.0
Platform: Android Orion [8.0]
Device model and OS version: Nexus one api26
Host: Dell G15 i7-11800H - Linux 22.04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants