ReactiveX / RxGroovy

RxJava bindings for Groovy
Apache License 2.0
158 stars 25 forks source link

Compilation Failure 'General error during class generation: rx.lang.groovy.RxGroovyPropertiesModuleFactory' #7

Open AndrewReitz opened 9 years ago

AndrewReitz commented 9 years ago
compile('io.reactivex:rxgroovy:1.0.0') {
  exclude group: 'org.codehaus.groovy' // exclude since Android uses grooid
}
General error during class generation: rx.lang.groovy.RxGroovyPropertiesModuleFactory cannot be cast to org.codehaus.groovy.runtime.m12n.PropertiesModuleFactory
java.lang.ClassCastException: rx.lang.groovy.RxGroovyPropertiesModuleFactory cannot be cast to org.codehaus.groovy.runtime.m12n.PropertiesModuleFactory
    at org.codehaus.groovy.runtime.m12n.StandardPropertiesModuleFactory.newModule(StandardPropertiesModuleFactory.java:38)
    at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanExtensionModuleFromProperties(ExtensionModuleScanner.java:76)
    at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanExtensionModuleFromMetaInf(ExtensionModuleScanner.java:71)
    at org.codehaus.groovy.runtime.m12n.ExtensionModuleScanner.scanClasspathModules(ExtensionModuleScanner.java:53)
    at org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport$ExtensionMethodCache.getExtensionMethods(StaticTypeCheckingSupport.java:1850)
    at org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport.findDGMMethodsForClassNode(StaticTypeCheckingSupport.java:181)
    at org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport.findDGMMethodsForClassNode(StaticTypeCheckingSupport.java:167)
    at org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport.findDGMMethodsByNameAndArguments(StaticTypeCheckingSupport.java:883)
    at org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport.findDGMMethodsByNameAndArguments(StaticTypeCheckingSupport.java:870)
    at org.codehaus.groovy.classgen.asm.sc.StaticTypesCallSiteWriter.makeGetPropertySite(StaticTypesCallSiteWriter.java:185)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitAttributeOrProperty(AsmClassGenerator.java:955)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitPropertyExpression(AsmClassGenerator.java:991)
    at org.codehaus.groovy.ast.expr.PropertyExpression.visit(PropertyExpression.java:55)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitCastExpression(AsmClassGenerator.java:725)
    at org.codehaus.groovy.ast.expr.CastExpression.visit(CastExpression.java:66)
    at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.evaluateEqual(BinaryExpressionHelper.java:313)
    at org.codehaus.groovy.classgen.asm.sc.StaticTypesBinaryExpressionMultiTypeDispatcher.evaluateEqual(StaticTypesBinaryExpressionMultiTypeDispatcher.java:148)
    at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.eval(BinaryExpressionHelper.java:81)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitBinaryExpression(AsmClassGenerator.java:636)
    at org.codehaus.groovy.ast.expr.BinaryExpression.visit(BinaryExpression.java:49)
    at org.codehaus.groovy.classgen.asm.StatementWriter.writeExpressionStatement(StatementWriter.java:604)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitExpressionStatement(AsmClassGenerator.java:618)
    at org.codehaus.groovy.ast.stmt.ExpressionStatement.visit(ExpressionStatement.java:40)
    at org.codehaus.groovy.classgen.asm.StatementWriter.writeBlockStatement(StatementWriter.java:81)
    at org.codehaus.groovy.classgen.asm.sc.StaticTypesStatementWriter.writeBlockStatement(StaticTypesStatementWriter.java:50)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitBlockStatement(AsmClassGenerator.java:564)
    at org.codehaus.groovy.ast.stmt.BlockStatement.visit(BlockStatement.java:69)
    at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClassCodeContainer(ClassCodeVisitorSupport.java:101)
    at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitConstructorOrMethod(ClassCodeVisitorSupport.java:112)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitStdMethod(AsmClassGenerator.java:428)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitConstructorOrMethod(AsmClassGenerator.java:385)
    at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitConstructor(ClassCodeVisitorSupport.java:119)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitConstructor(AsmClassGenerator.java:500)
    at org.codehaus.groovy.ast.ClassNode.visitContents(ClassNode.java:1079)
    at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClass(ClassCodeVisitorSupport.java:50)
    at org.codehaus.groovy.classgen.AsmClassGenerator.visitClass(AsmClassGenerator.java:231)
Error:Execution failed for task ':compileDebugGroovy'.
> Compilation failed; see the compiler error output for details.
Information:BUILD FAILED
Information:Total time: 3.843 secs
    at org.codehaus.groovy.control.CompilationUnit$16.call(CompilationUnit.java:810)
    at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1052)
    at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:588)
    at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:566)
    at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:543)
    at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:522)
    at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:122)
    at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:47)
    at org.gradle.api.internal.tasks.compile.daemon.CompilerDaemonServer.execute(CompilerDaemonServer.java:53)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:483)
    at org.gradle.messaging.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)
    at org.gradle.messaging.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
    at org.gradle.messaging.remote.internal.hub.MessageHub$Handler.run(MessageHub.java:360)
    at org.gradle.internal.concurrent.DefaultExecutorFactory$StoppableExecutorImpl$1.run(DefaultExecutorFactory.java:64)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
aaronzirbes commented 9 years ago

I have the same problem Andrew. Works fine in pure Groovy app, but fails in my Ratpack app.

aaronzirbes commented 9 years ago

Had to add this to my gradle build

compile ratpack.dependency('rx')

rather than directly adding the rx-java dependency

AndrewReitz commented 9 years ago

@aaronzirbes do you know what ratpack.dependency('rx') does differently? Using ratpack isn't really an option for me. If I had to guess I would say it is just loading RxJava and not RxGroovy, which is what I have been using.

aaronzirbes commented 9 years ago

It might be because there are different versions of groovy used to run vs. compile? That class is extending PropertiesModuleFactory so it shouldn't be getting that cast exception.

https://github.com/ReactiveX/RxGroovy/blob/1.x/src/main/java/rx/lang/groovy/RxGroovyPropertiesModuleFactory.java#L30

Check your runtime dependency tree with gradle dependencies, and then see if you can find any conflicts in there?

Shots in the dark really at this point...

mflorence99 commented 8 years ago

@pieces029 @aaronzirbes Are you still experiencing this issue? I just started to use RxGroovy and got the same error. I did have a Ratpack dependency in the failing project and that smelled even more like this issue. I didn't really need that dependency so I refactored it out -- but sadly the same error.

Any insight would be greatly appreciated. My stack trace is essentially the same so I won't post that. These are my declared dependencies:

dependencies {
  compile 'com.google.guava:guava:19.0'
  compile 'com.google.inject:guice:4.0'
  compile 'com.startwire:common:1.101.3'
  compile 'io.reactivex:rxgroovy:1.0.3'
  compile 'org.codehaus.groovy:groovy-all:2.4.6:indy'
  storm 'org.apache.storm:storm-core:0.10.0'
  testCompile 'cglib:cglib:3.1'
  testCompile 'org.spockframework:spock-core:1.0-groovy-2.4'
}

Of course, you don't know anything about my private JAR and it sucks in a lot. Following is the dependency tree. I've looked at it up and down but I can't see anything that looks like trouble. (I did try reverting back to Groovy 2.4.5, but that didn't change anything).

+--- com.google.guava:guava:19.0
+--- com.google.inject:guice:4.0
|    +--- javax.inject:javax.inject:1
|    +--- aopalliance:aopalliance:1.0
|    \--- com.google.guava:guava:16.0.1 -> 19.0
+--- com.startwire:common:1.101.3
|    +--- org.apache.commons:commons-dbcp2:2.1.1
|    |    +--- org.apache.commons:commons-pool2:2.4.2
|    |    \--- commons-logging:commons-logging:1.2
|    +--- redis.clients:jedis:2.7.3
|    |    \--- org.apache.commons:commons-pool2:2.3 -> 2.4.2
|    +--- com.amazonaws:aws-java-sdk:1.10.62
|    |    +--- com.amazonaws:aws-java-sdk-support:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62
|    |    |         +--- commons-logging:commons-logging:1.1.3 -> 1.2
|    |    |         +--- org.apache.httpcomponents:httpclient:4.3.6
|    |    |         |    +--- org.apache.httpcomponents:httpcore:4.3.3
|    |    |         |    +--- commons-logging:commons-logging:1.1.3 -> 1.2
|    |    |         |    \--- commons-codec:commons-codec:1.6
|    |    |         +--- com.fasterxml.jackson.core:jackson-databind:2.5.3
|    |    |         |    +--- com.fasterxml.jackson.core:jackson-annotations:2.5.0
|    |    |         |    \--- com.fasterxml.jackson.core:jackson-core:2.5.3
|    |    |         \--- joda-time:joda-time:2.8.1
|    |    +--- com.amazonaws:aws-java-sdk-simpledb:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-simpleworkflow:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-storagegateway:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-route53:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-s3:1.10.62
|    |    |    +--- com.amazonaws:aws-java-sdk-kms:1.10.62
|    |    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-importexport:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-sts:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-sqs:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-rds:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-redshift:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-elasticbeanstalk:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-glacier:1.10.62
|    |    |    +--- com.amazonaws:aws-java-sdk-sqs:1.10.62 (*)
|    |    |    +--- com.amazonaws:aws-java-sdk-sns:1.10.62
|    |    |    |    +--- com.amazonaws:aws-java-sdk-sqs:1.10.62 (*)
|    |    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    |    +--- com.amazonaws:aws-java-sdk-s3:1.10.62 (*)
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-iam:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-datapipeline:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-elasticloadbalancing:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-emr:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-elasticache:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-elastictranscoder:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-ec2:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-dynamodb:1.10.62
|    |    |    +--- com.amazonaws:aws-java-sdk-s3:1.10.62 (*)
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-sns:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudtrail:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudwatch:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-logs:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-events:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cognitoidentity:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cognitosync:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-directconnect:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudformation:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudfront:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-kinesis:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-opsworks:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-ses:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-autoscaling:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudsearch:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudwatchmetrics:1.10.62
|    |    |    +--- com.amazonaws:aws-java-sdk-cloudwatch:1.10.62 (*)
|    |    |    +--- com.amazonaws:aws-java-sdk-dynamodb:1.10.62 (*)
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-swf-libraries:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-simpleworkflow:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-codedeploy:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-codepipeline:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-kms:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-config:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-lambda:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-ecs:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-ecr:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-cloudhsm:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-ssm:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-workspaces:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-machinelearning:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-directory:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-efs:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-codecommit:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-devicefarm:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-elasticsearch:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-waf:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-marketplacecommerceanalytics:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-inspector:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-iot:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-api-gateway:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-acm:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-gamelift:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-dms:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    +--- com.amazonaws:aws-java-sdk-marketplacemeteringservice:1.10.62
|    |    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    |    \--- com.amazonaws:aws-java-sdk-core:1.10.62 (*)
|    +--- com.google.inject:guice:4.0 (*)
|    +--- org.apache.opennlp:opennlp-tools:1.6.0
|    +--- org.codehaus.groovy:groovy-all:2.4.6
|    +--- com.google.guava:guava:19.0
|    +--- javax.mail:mail:1.4.7
|    |    \--- javax.activation:activation:1.1
|    +--- org.codehaus.gpars:gpars:1.2.1
|    |    +--- org.multiverse:multiverse-core:0.7.0
|    |    \--- org.codehaus.jsr166-mirror:jsr166y:1.7.0
|    +--- org.apache.derby:derby:10.12.1.1
|    +--- org.codehaus.groovy.modules.http-builder:http-builder:0.7.1
|    |    +--- org.apache.httpcomponents:httpclient:4.2.1 -> 4.3.6 (*)
|    |    +--- net.sf.json-lib:json-lib:2.3
|    |    |    +--- commons-beanutils:commons-beanutils:1.8.0
|    |    |    |    \--- commons-logging:commons-logging:1.1.1 -> 1.2
|    |    |    +--- commons-collections:commons-collections:3.2.1
|    |    |    +--- commons-lang:commons-lang:2.4
|    |    |    +--- commons-logging:commons-logging:1.1.1 -> 1.2
|    |    |    \--- net.sf.ezmorph:ezmorph:1.0.6
|    |    |         \--- commons-lang:commons-lang:2.3 -> 2.4
|    |    +--- net.sourceforge.nekohtml:nekohtml:1.9.16
|    |    |    \--- xerces:xercesImpl:2.9.1
|    |    |         \--- xml-apis:xml-apis:1.3.04
|    |    \--- xml-resolver:xml-resolver:1.2
|    +--- org.elasticsearch:elasticsearch-groovy:1.7.3
|    |    +--- org.elasticsearch:elasticsearch:1.7.3
|    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    +--- org.apache.lucene:lucene-analyzers-common:4.10.4
|    |    |    |    \--- org.apache.lucene:lucene-core:4.10.4
|    |    |    +--- org.apache.lucene:lucene-queries:4.10.4
|    |    |    |    \--- org.apache.lucene:lucene-core:4.10.4
|    |    |    +--- org.apache.lucene:lucene-memory:4.10.4
|    |    |    |    \--- org.apache.lucene:lucene-core:4.10.4
|    |    |    +--- org.apache.lucene:lucene-highlighter:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-memory:4.10.4 (*)
|    |    |    |    \--- org.apache.lucene:lucene-queries:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-queryparser:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-queries:4.10.4 (*)
|    |    |    |    \--- org.apache.lucene:lucene-sandbox:4.10.4
|    |    |    |         \--- org.apache.lucene:lucene-core:4.10.4
|    |    |    +--- org.apache.lucene:lucene-sandbox:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-suggest:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-analyzers-common:4.10.4 (*)
|    |    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-misc:4.10.4
|    |    |    |    |    \--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    \--- org.apache.lucene:lucene-queries:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-misc:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-join:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    \--- org.apache.lucene:lucene-grouping:4.10.4
|    |    |    |         +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |         \--- org.apache.lucene:lucene-queries:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-grouping:4.10.4 (*)
|    |    |    +--- org.apache.lucene:lucene-spatial:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-core:4.10.4
|    |    |    |    +--- org.apache.lucene:lucene-queries:4.10.4 (*)
|    |    |    |    \--- com.spatial4j:spatial4j:0.4.1
|    |    |    \--- org.yaml:snakeyaml:1.12
|    |    \--- org.codehaus.groovy:groovy-all:2.4.4 -> 2.4.6
|    +--- com.vividsolutions:jts:1.13
|    +--- org.apache.commons:commons-lang3:3.4
|    +--- javax.mail:javax.mail-api:1.5.5
|    +--- org.apache.commons:commons-pool2:2.4.1 -> 2.4.2
|    \--- org.postgresql:postgresql:9.4-1203-jdbc42
+--- commons-cli:commons-cli:1.3.1
+--- io.reactivex:rxgroovy:1.0.3
|    +--- io.reactivex:rxjava:1.0.15
|    \--- org.codehaus.groovy:groovy-all:2.4.5 -> 2.4.6
+--- org.codehaus.groovy:groovy-all:2.4.6
\--- org.apache.storm:storm-core:0.10.0
     +--- com.esotericsoftware.kryo:kryo:2.21
     |    +--- com.esotericsoftware.reflectasm:reflectasm:1.07
     |    |    \--- org.ow2.asm:asm:4.0
     |    \--- com.esotericsoftware.minlog:minlog:1.2
     +--- org.clojure:clojure:1.6.0
     +--- com.googlecode.disruptor:disruptor:2.10.4
     +--- org.apache.logging.log4j:log4j-api:2.1
     +--- org.apache.logging.log4j:log4j-core:2.1
     |    \--- org.apache.logging.log4j:log4j-api:2.1
     +--- org.apache.logging.log4j:log4j-slf4j-impl:2.1
     |    +--- org.slf4j:slf4j-api:1.7.7
     |    \--- org.apache.logging.log4j:log4j-api:2.1
     +--- org.slf4j:log4j-over-slf4j:1.6.6
     |    \--- org.slf4j:slf4j-api:1.6.6 -> 1.7.7
     +--- org.apache.hadoop:hadoop-auth:2.4.0
     +--- javax.servlet:servlet-api:2.5
     \--- org.slf4j:slf4j-api:1.7.7
AndrewReitz commented 8 years ago

I am actually not seeing this issue anymore on the latest version of the groovy android plugin, and latest version of this library. Should I update this issue's name to reflect more of what the issue is?

mflorence99 commented 8 years ago

@pieces029 Good point: I am not doing anything at all on the Android. It is definitely that same error, though.

mflorence99 commented 8 years ago

Just an update: I forked the repo and rebuilt a JAR with io.reactivex:rxjava:1.1.2 and org.codehaus.groovy:groovy-all:2.4.6:indy just to have the same dependencies as the rest of my project, but no difference.

When I've seen inexplicable cast cast errors before it's been because there's more than one version of that class floating around -- essentially, the same class in two or more JARs. That jibes with the dependency theory earlier in this thread. As time permits, I will keep experimenting.

mflorence99 commented 8 years ago

FWIW just on a hunch, I finally found it! I think there's a Groovy issue, rather than an RxGroovy problem.

I had been using the @CompileDynamic annotation. When I remove it, this error goes away.

Krotki commented 8 years ago

I see same error in my spring boot app. After I commented out all @CompileStatic annotations, the error goes away.