Unable to run in multiple devices
See original GitHub issueHello. I’m new to Marathon and I’m having some difficulty executing the tests in parallel on different devices. I’m trying to execute the tests using an emulator and a real device, but only the emulator executes the tests. I’m using the following configuration:
name: “HelloWorld” outputDir: “build/reports/marathon” vendorConfiguration: type: “Android” applicationApk: “app/build/outputs/apk/debug/app-debug.apk” testApplicationApk: “app/build/outputs/apk/androidTest/debug/app-debug-androidTest.apk”
The tests execute fine on the emulator. However, on the real device, I’m getting the following error:
> D 15:44:34.926 [main @coroutine#40] <QueueActor[DevicePoolId(name=omni)]> handle test results 127.0.0.1:5037:emulator-5554
D 15:44:34.926 [main @coroutine#40] <QueueActor[DevicePoolId(name=omni)]> request next batch for device 127.0.0.1:5037:emulator-5554
E 15:44:34.936 [main @coroutine#68] <D.0.0.1:5037:0051948259]> Error Job was cancelled
kotlinx.coroutines.JobCancellationException: Job was cancelled
at kotlinx.coroutines.JobSupport.cancel(JobSupport.kt:1578)
at kotlinx.coroutines.Job$DefaultImpls.cancel$default(Job.kt:189)
at com.malinskiy.marathon.execution.DevicePoolActor.terminate(DevicePoolActor.kt:132)
at com.malinskiy.marathon.execution.DevicePoolActor.onQueueTerminated(DevicePoolActor.kt:88)
at com.malinskiy.marathon.execution.DevicePoolActor.receive(DevicePoolActor.kt:51)
at com.malinskiy.marathon.execution.DevicePoolActor.receive(DevicePoolActor.kt:26)
at com.malinskiy.marathon.actor.Actor$delegate$1.invokeSuspend(Actor.kt:31)
(Coroutine boundary)
at com.malinskiy.marathon.execution.device.DeviceActor$initialize$2$1.invokeSuspend(DeviceActor.kt:165)
at com.malinskiy.marathon.execution.RetryKt.withRetry(Retry.kt:11)
at com.malinskiy.marathon.execution.device.DeviceActor$initialize$2.invokeSuspend(DeviceActor.kt:162)
Caused by: kotlinx.coroutines.JobCancellationException: Job was cancelled
at kotlinx.coroutines.JobSupport.cancel(JobSupport.kt:1578)
at kotlinx.coroutines.Job$DefaultImpls.cancel$default(Job.kt:189)
at com.malinskiy.marathon.execution.DevicePoolActor.terminate(DevicePoolActor.kt:132)
at com.malinskiy.marathon.execution.DevicePoolActor.onQueueTerminated(DevicePoolActor.kt:88)
at com.malinskiy.marathon.execution.DevicePoolActor.receive(DevicePoolActor.kt:51)
at com.malinskiy.marathon.execution.DevicePoolActor.receive(DevicePoolActor.kt:26)
at com.malinskiy.marathon.actor.Actor$delegate$1.invokeSuspend(Actor.kt:31)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:279)
at kotlinx.coroutines.BlockingCoroutine.joinBlocking(Builders.kt:85)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(Builders.kt:59)
at kotlinx.coroutines.BuildersKt.runBlocking(Unknown Source)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking$default(Builders.kt:38)
at kotlinx.coroutines.BuildersKt.runBlocking$default(Unknown Source)
at com.malinskiy.marathon.Marathon.run(Marathon.kt:52)
at com.malinskiy.marathon.cli.ApplicationViewKt$main$1.invoke(ApplicationView.kt:62)
at com.malinskiy.marathon.cli.ApplicationViewKt$main$1.invoke(ApplicationView.kt:29)
at com.xenomachina.argparser.SystemExitExceptionKt.mainBody(SystemExitException.kt:74)
at com.xenomachina.argparser.SystemExitExceptionKt.mainBody$default(SystemExitException.kt:72)
at com.malinskiy.marathon.cli.ApplicationViewKt.main(ApplicationView.kt:27)
D 15:44:34.937 [main @coroutine#68] <D.0.0.1:5037:0051948259]> terminate 127.0.0.1:5037:0051948259
Looking at the report, I get the following info: https://drive.google.com/file/d/1dFOtbFSlvjBnQez6_L647BpQeqp8hWRn/view?usp=sharing
Am I missing something? I’m currently using Marathon version 0.7.3.
Issue Analytics
- State:
- Created a year ago
- Comments:9 (5 by maintainers)

Top Related StackOverflow Question
No worries at all. Yeah, you can achieve this behavior by using one of the https://marathonlabs.github.io/marathon/doc/configuration.html#pooling-strategy Each pool executes all of the tests independently.
Looks like this problem was solved