java.lang.RuntimeException: Unable to configure class node for class grails.events.Events due to malformed parameterized types

GitHub | anti43 | 5 months ago
  1. 0

    Task test fails with MalformedParameterizedTypeException

    GitHub | 5 months ago | anti43
    java.lang.RuntimeException: Unable to configure class node for class grails.events.Events due to malformed parameterized types
  2. 0

    Grails 3 Gradle Build Error - MalformedParameterizedTypeException

    Stack Overflow | 1 year ago | Brandon Wagner
    java.lang.reflect.MalformedParameterizedTypeException
  3. 0

    When a dependency changes signature, and this dependency is used in an AST transformation, a compilation error can occur, but the error message is presented to the developer does not give any hint to, where the error was. In this case, the Reactor framework used in Grails 3.0.0 changed version (started using generics) to a never version in Grails 3.0.9. This caused the following compilation error: {code} General error during class generation: java.lang.reflect.MalformedParameterizedTypeException ​ java.lang.reflect.MalformedParameterizedTypeException at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.validateConstructorArguments(ParameterizedTypeImpl.java:58) at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.<init>(ParameterizedTypeImpl.java:51) at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.make(ParameterizedTypeImpl.java:92) at sun.reflect.generics.factory.CoreReflectionFactory.makeParameterizedType(CoreReflectionFactory.java:105) at sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:140) at sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49) at sun.reflect.generics.repository.MethodRepository.getReturnType(MethodRepository.java:68) at java.lang.reflect.Method.getGenericReturnType(Method.java:255) at org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:364) at org.codehaus.groovy.ast.ClassNode.lazyClassInit(ClassNode.java:265) at org.codehaus.groovy.ast.ClassNode.getUnresolvedSuperClass(ClassNode.java:1004) at org.codehaus.groovy.ast.ClassNode.getUnresolvedSuperClass(ClassNode.java:999) at org.codehaus.groovy.ast.ClassNode.getSuperClass(ClassNode.java:993) at org.codehaus.groovy.ast.ClassNode.isDerivedFrom(ClassNode.java:936) at org.codehaus.groovy.classgen.asm.InvocationWriter.castToNonPrimitiveIfNecessary(InvocationWriter.java:858) at org.codehaus.groovy.classgen.asm.OperandStack.doConvertAndCast(OperandStack.java:347) at org.codehaus.groovy.classgen.asm.OperandStack.doGroovyCast(OperandStack.java:282) at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.evaluateEqual(BinaryExpressionHelper.java:400) at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.eval(BinaryExpressionHelper.java:84) at org.codehaus.groovy.classgen.AsmClassGenerator.visitBinaryExpression(AsmClassGenerator.java:638) at org.codehaus.groovy.ast.expr.BinaryExpression.visit(BinaryExpression.java:51) at org.codehaus.groovy.classgen.asm.StatementWriter.writeExpressionStatement(StatementWriter.java:607) at org.codehaus.groovy.classgen.asm.OptimizingStatementWriter.writeExpressionStatement(OptimizingStatementWriter.java:349) at org.codehaus.groovy.classgen.AsmClassGenerator.visitExpressionStatement(AsmClassGenerator.java:620) at org.codehaus.groovy.ast.stmt.ExpressionStatement.visit(ExpressionStatement.java:42) at org.codehaus.groovy.classgen.asm.StatementWriter.writeBlockStatement(StatementWriter.java:84) at org.codehaus.groovy.classgen.asm.OptimizingStatementWriter.writeBlockStatement(OptimizingStatementWriter.java:158) at org.codehaus.groovy.classgen.AsmClassGenerator.visitBlockStatement(AsmClassGenerator.java:566) at org.codehaus.groovy.ast.stmt.BlockStatement.visit(BlockStatement.java:71) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClassCodeContainer(ClassCodeVisitorSupport.java:104) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitConstructorOrMethod(ClassCodeVisitorSupport.java:115) at org.codehaus.groovy.classgen.AsmClassGenerator.visitStdMethod(AsmClassGenerator.java:430) at org.codehaus.groovy.classgen.AsmClassGenerator.visitConstructorOrMethod(AsmClassGenerator.java:387) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitMethod(ClassCodeVisitorSupport.java:126) at org.codehaus.groovy.classgen.AsmClassGenerator.visitMethod(AsmClassGenerator.java:507) at org.codehaus.groovy.ast.ClassNode.visitContents(ClassNode.java:1086) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClass(ClassCodeVisitorSupport.java:53) at org.codehaus.groovy.classgen.AsmClassGenerator.visitClass(AsmClassGenerator.java:233) at org.codehaus.groovy.control.CompilationUnit$16.call(CompilationUnit.java:813) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1055) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:591) at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:569) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:546) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:525) at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:180) at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:53) 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:497) 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.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54) at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40) 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) ​ 1 error {code} If the compilation error was caught in `org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:364)` it would be possible to output what class and what the reason was for the error before re-throwing it.

    Apache's JIRA Issue Tracker | 1 year ago | Søren Berg Glasius
    java.lang.reflect.MalformedParameterizedTypeException
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    When a dependency changes signature, and this dependency is used in an AST transformation, a compilation error can occur, but the error message is presented to the developer does not give any hint to, where the error was. In this case, the Reactor framework used in Grails 3.0.0 changed version (started using generics) to a never version in Grails 3.0.9. This caused the following compilation error: {code} General error during class generation: java.lang.reflect.MalformedParameterizedTypeException ​ java.lang.reflect.MalformedParameterizedTypeException at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.validateConstructorArguments(ParameterizedTypeImpl.java:58) at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.<init>(ParameterizedTypeImpl.java:51) at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.make(ParameterizedTypeImpl.java:92) at sun.reflect.generics.factory.CoreReflectionFactory.makeParameterizedType(CoreReflectionFactory.java:105) at sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:140) at sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49) at sun.reflect.generics.repository.MethodRepository.getReturnType(MethodRepository.java:68) at java.lang.reflect.Method.getGenericReturnType(Method.java:255) at org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:364) at org.codehaus.groovy.ast.ClassNode.lazyClassInit(ClassNode.java:265) at org.codehaus.groovy.ast.ClassNode.getUnresolvedSuperClass(ClassNode.java:1004) at org.codehaus.groovy.ast.ClassNode.getUnresolvedSuperClass(ClassNode.java:999) at org.codehaus.groovy.ast.ClassNode.getSuperClass(ClassNode.java:993) at org.codehaus.groovy.ast.ClassNode.isDerivedFrom(ClassNode.java:936) at org.codehaus.groovy.classgen.asm.InvocationWriter.castToNonPrimitiveIfNecessary(InvocationWriter.java:858) at org.codehaus.groovy.classgen.asm.OperandStack.doConvertAndCast(OperandStack.java:347) at org.codehaus.groovy.classgen.asm.OperandStack.doGroovyCast(OperandStack.java:282) at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.evaluateEqual(BinaryExpressionHelper.java:400) at org.codehaus.groovy.classgen.asm.BinaryExpressionHelper.eval(BinaryExpressionHelper.java:84) at org.codehaus.groovy.classgen.AsmClassGenerator.visitBinaryExpression(AsmClassGenerator.java:638) at org.codehaus.groovy.ast.expr.BinaryExpression.visit(BinaryExpression.java:51) at org.codehaus.groovy.classgen.asm.StatementWriter.writeExpressionStatement(StatementWriter.java:607) at org.codehaus.groovy.classgen.asm.OptimizingStatementWriter.writeExpressionStatement(OptimizingStatementWriter.java:349) at org.codehaus.groovy.classgen.AsmClassGenerator.visitExpressionStatement(AsmClassGenerator.java:620) at org.codehaus.groovy.ast.stmt.ExpressionStatement.visit(ExpressionStatement.java:42) at org.codehaus.groovy.classgen.asm.StatementWriter.writeBlockStatement(StatementWriter.java:84) at org.codehaus.groovy.classgen.asm.OptimizingStatementWriter.writeBlockStatement(OptimizingStatementWriter.java:158) at org.codehaus.groovy.classgen.AsmClassGenerator.visitBlockStatement(AsmClassGenerator.java:566) at org.codehaus.groovy.ast.stmt.BlockStatement.visit(BlockStatement.java:71) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClassCodeContainer(ClassCodeVisitorSupport.java:104) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitConstructorOrMethod(ClassCodeVisitorSupport.java:115) at org.codehaus.groovy.classgen.AsmClassGenerator.visitStdMethod(AsmClassGenerator.java:430) at org.codehaus.groovy.classgen.AsmClassGenerator.visitConstructorOrMethod(AsmClassGenerator.java:387) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitMethod(ClassCodeVisitorSupport.java:126) at org.codehaus.groovy.classgen.AsmClassGenerator.visitMethod(AsmClassGenerator.java:507) at org.codehaus.groovy.ast.ClassNode.visitContents(ClassNode.java:1086) at org.codehaus.groovy.ast.ClassCodeVisitorSupport.visitClass(ClassCodeVisitorSupport.java:53) at org.codehaus.groovy.classgen.AsmClassGenerator.visitClass(AsmClassGenerator.java:233) at org.codehaus.groovy.control.CompilationUnit$16.call(CompilationUnit.java:813) at org.codehaus.groovy.control.CompilationUnit.applyToPrimaryClassNodes(CompilationUnit.java:1055) at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:591) at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:569) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:546) at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:525) at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:180) at org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:53) 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:497) 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.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54) at org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40) 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) ​ 1 error {code} If the compilation error was caught in `org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:364)` it would be possible to output what class and what the reason was for the error before re-throwing it.

    Apache's JIRA Issue Tracker | 1 year ago | Søren Berg Glasius
    java.lang.reflect.MalformedParameterizedTypeException
  6. 0

    [groovy-user] Recent GMaven failures - MalformedParameterizedTypeException

    Google Groups | 8 years ago | tto...@comcast.net
    org.apache.maven.lifecycle.LifecycleExecutionException

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.reflect.MalformedParameterizedTypeException

      No message provided

      at sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.validateConstructorArguments()
    2. Java RT
      Method.getGenericReturnType
      1. sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.validateConstructorArguments(ParameterizedTypeImpl.java:58)
      2. sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.<init>(ParameterizedTypeImpl.java:51)
      3. sun.reflect.generics.reflectiveObjects.ParameterizedTypeImpl.make(ParameterizedTypeImpl.java:92)
      4. sun.reflect.generics.factory.CoreReflectionFactory.makeParameterizedType(CoreReflectionFactory.java:105)
      5. sun.reflect.generics.visitor.Reifier.visitClassTypeSignature(Reifier.java:140)
      6. sun.reflect.generics.tree.ClassTypeSignature.accept(ClassTypeSignature.java:49)
      7. sun.reflect.generics.repository.MethodRepository.getReturnType(MethodRepository.java:68)
      8. java.lang.reflect.Method.getGenericReturnType(Method.java:255)
      8 frames
    3. Groovy
      TraitComposer.doExtendTraits
      1. org.codehaus.groovy.vmplugin.v5.Java5.configureClassNode(Java5.java:365)
      2. org.codehaus.groovy.ast.ClassNode.lazyClassInit(ClassNode.java:265)
      3. org.codehaus.groovy.ast.ClassNode.getInterfaces(ClassNode.java:360)
      4. org.codehaus.groovy.ast.ClassNode.declaresInterface(ClassNode.java:976)
      5. org.codehaus.groovy.ast.ClassNode.declaresInterface(ClassNode.java:981)
      6. org.codehaus.groovy.ast.ClassNode.implementsInterface(ClassNode.java:956)
      7. org.codehaus.groovy.transform.stc.StaticTypeCheckingSupport.implementsInterfaceOrIsSubclassOf(StaticTypeCheckingSupport.java:771)
      8. org.codehaus.groovy.ast.tools.GenericsUtils.parameterizeType(GenericsUtils.java:218)
      9. org.codehaus.groovy.transform.trait.Traits.collectAllInterfacesReverseOrder(Traits.java:274)
      10. org.codehaus.groovy.transform.trait.TraitComposer.findTraits(TraitComposer.java:116)
      11. org.codehaus.groovy.transform.trait.TraitComposer.doExtendTraits(TraitComposer.java:101)
      11 frames
    4. Grails
      GlobalGrailsClassInjectorTransformation.visit
      1. org.grails.compiler.injection.TraitInjectionUtils.doInjectionInternal(TraitInjectionUtils.java:72)
      2. org.grails.compiler.injection.TraitInjectionUtils.processTraitsForNode(TraitInjectionUtils.java:104)
      3. org.grails.compiler.injection.GlobalGrailsClassInjectorTransformation.visit(GlobalGrailsClassInjectorTransformation.groovy:122)
      3 frames
    5. Groovy
      CompilationUnit.compile
      1. org.codehaus.groovy.transform.ASTTransformationVisitor$3.call(ASTTransformationVisitor.java:321)
      2. org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:931)
      3. org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:593)
      4. org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:569)
      5. org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:546)
      6. org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:525)
      6 frames
    6. org.gradle.api
      CompilerDaemonServer.execute
      1. org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:167)
      2. org.gradle.api.internal.tasks.compile.ApiGroovyCompiler.execute(ApiGroovyCompiler.java:54)
      3. org.gradle.api.internal.tasks.compile.daemon.CompilerDaemonServer.execute(CompilerDaemonServer.java:31)
      3 frames
    7. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    8. org.gradle.process
      WorkerAction.run
      1. org.gradle.process.internal.worker.request.WorkerAction.run(WorkerAction.java:87)
      1 frame
    9. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      4. java.lang.reflect.Method.invoke(Method.java:498)
      4 frames
    10. org.gradle.internal
      MessageHub$Handler.run
      1. org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)
      2. org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
      3. org.gradle.internal.remote.internal.hub.MessageHub$Handler.run(MessageHub.java:377)
      3 frames
    11. Gradle Core
      StoppableExecutorImpl$1.run
      1. org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:54)
      2. org.gradle.internal.concurrent.StoppableExecutorImpl$1.run(StoppableExecutorImpl.java:40)
      2 frames
    12. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      3. java.lang.Thread.run(Thread.java:745)
      3 frames