Gradle worker stuck at the end on the tests? my fault?


(lqb) #1

I’m porting our build system to gradle (previously based on just ant and working just ok), and I’m a bit blocked with a problem.

I admit that my jUnits (+1000) are not all that well designed, but gradle is not making it easy… my build is stuck in the middle without telling anything useful. My last lines in debug mode are:

… 18:21:12.342 [DEBUG] [TestEventLogger]

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 18:21:12.353 [DEBUG] [TestEventLogger]

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) 18:21:12.361 [DEBUG] [TestEventLogger]

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) 18:21:12.370 [DEBUG] [TestEventLogger]

at java.lang.reflect.Method.invoke(Method.java:597) 18:21:12.380 [DEBUG] [TestEventLogger]

at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44) 18:21:12.388 [DEBUG] [TestEventLogger]

at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15) 18:21:12.397 [DEBUG] [TestEventLogger]

at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41) 18:21:12.407 [DEBUG] [TestEventLogger]

at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20) 18:21:12.415 [DEBUG] [TestEventLogger]

at org.junit.internal.runners.statements.FailOnTimeout$1.run(FailOnTimeout.java:28) 18:21:12.425 [DEBUG] [TestEventLogger] 18:21:12.435 [DEBUG] [TestEventLogger] com..TestCustomScreen FAILED 18:21:12.445 [DEBUG] [TestEventLogger] 18:21:12.454 [DEBUG] [TestEventLogger] Gradle Worker 8 FAILED

Usually, in debug mode I can see when a test starts, and when it finishes so if a test were be blocked in the middle, I’d see it… But there it just says that and nothing more. I’m running it with maxParallelForks=1.

I’m using gradle 1.1.

Any idea why? how to proceed in this scenario?

Thanks!!


(Peter Niederwieser) #2

‘test.testLogging.events “started”, “passed”, “skipped”, “failed”’ will give you more console logging. For further test logging options see the DSL reference.


(lqb) #3

thanks for your quick reply… I have already done that, but still… can’t see anything useful… let me paste you the last few lines…

http://pastebin.com/X7PPBcRu


(Peter Niederwieser) #4

The first thing to do is to find out which test is causing the problem. Hopefully, the log will give some hints on that. Next thing is to investigate and debug that test.


(lqb) #5

I already know that…

I realized that by taking a couple of jUnits which are timing out, it happens less often…

Please, can you at least have a look to the log before, and tell me that these lines:

18:52:00.530 [DEBUG] [org.gradle.messaging.remote.internal.Router] Received route unavailable. Message: [ProducerUnavailable id: 1a0892f7-b868-48f3-a336-022a9f344ee9] 18:52:00.540 [DEBUG] [TestEventLogger]

at org.gradle.messaging.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35) 18:52:00.560 [DEBUG] [org.gradle.messaging.remote.internal.Router] Received route unavailable. Message: [ConsumerUnavailable id: 053da2b2-c592-431e-ae83-d592e417e7e6]

are not anything related with this problem:

http://issues.gradle.org/browse/GRADLE-1903 http://forums.gradle.org/gradle/topics/findbus_plugin_down

I just tried with the latest snapshot and still happening :S


(Peter Niederwieser) #6

Without a way to reproduce these problems, it’s hard to say. If you can isolate a problematic test, we may be able to dig deeper.