Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.0.9
-
None
-
None
Description
Doing early testing of some Groovy applications on Java 17 (ea31), and I'm encountering some exceptions like the following in unit tests. I'm testing on the 3.0.9 branch since 3.0.8 can't compile many of our Groovy classes against Java 17.
java.lang.IncompatibleClassChangeError: class String1_groovyProxy cannot implement sealed interface java.lang.constant.ConstantDesc java.base/java.lang.ClassLoader.defineClass1(Native Method) java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1012) java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:874) org.codehaus.groovy.runtime.ProxyGeneratorAdapter$InnerLoader.defineClass(ProxyGeneratorAdapter.java:847) org.codehaus.groovy.runtime.ProxyGeneratorAdapter.<init>(ProxyGeneratorAdapter.java:192) groovy.util.ProxyGenerator.lambda$createAdapter$0(ProxyGenerator.java:234) org.apache.groovy.util.concurrent.concurrentlinkedhashmap.ConcurrentLinkedHashMap.lambda$compute$0(ConcurrentLinkedHashMap.java:788) java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1708) org.apache.groovy.util.concurrent.concurrentlinkedhashmap.ConcurrentLinkedHashMap.compute(ConcurrentLinkedHashMap.java:800) org.apache.groovy.util.concurrent.concurrentlinkedhashmap.ConcurrentLinkedHashMap.computeIfAbsent(ConcurrentLinkedHashMap.java:777) org.codehaus.groovy.runtime.memoize.LRUCache.getAndPut(LRUCache.java:63) groovy.util.ProxyGenerator.createAdapter(ProxyGenerator.java:230) groovy.util.ProxyGenerator.instantiateDelegateWithBaseClass(ProxyGenerator.java:205) groovy.util.ProxyGenerator.instantiateDelegateWithBaseClass(ProxyGenerator.java:189) groovy.util.ProxyGenerator.instantiateDelegate(ProxyGenerator.java:181) groovy.util.ProxyGenerator.instantiateDelegate(ProxyGenerator.java:177) org.codehaus.groovy.runtime.DefaultGroovyMethods.asType(DefaultGroovyMethods.java:17910) org.codehaus.groovy.runtime.StringGroovyMethods.asType(StringGroovyMethods.java:208) org.codehaus.groovy.runtime.dgm$1158.doMethodInvoke(Unknown Source) groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1268)
I haven't tried to create a simple reproducer, but am happy to try to do so if the problem isn't already known or obvious.
Attachments
Issue Links
- relates to
-
GROOVY-10503 Embed ASM 9.2 in Groovy 2.5.x
- Closed