Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-9600

Picocli-related VersionProvider helper classes should be public to avoid access warnings

    XMLWordPrintableJSON

Details

    Description

      Otherwise results in errors on JDK9+ such as below:

      java.lang.IllegalAccessException: class groovyjarjarpicocli.CommandLine$DefaultFactory cannot access a member of class groovy.ui.GroovyMain$VersionProvider with modifiers ""
              at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:376)
              at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:647)
              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:490)
              at java.base/java.lang.reflect.ReflectAccess.newInstance(ReflectAccess.java:124)
              at java.base/jdk.internal.reflect.ReflectionFactory.newInstance(ReflectionFactory.java:346)
              at java.base/java.lang.Class.newInstance(Class.java:604)
              at groovyjarjarpicocli.CommandLine$DefaultFactory.create(CommandLine.java:5090)
              at groovyjarjarpicocli.CommandLine$DefaultFactory.create(CommandLine.java:5116)
              at groovyjarjarpicocli.CommandLine$DefaultFactory.createVersionProvider(CommandLine.java:5104)
              at groovyjarjarpicocli.CommandLine$Model$CommandSpec.updateVersionProvider(CommandLine.java:6698)
              at groovyjarjarpicocli.CommandLine$Model$CommandSpec.updateCommandAttributes(CommandLine.java:6673)
              at groovyjarjarpicocli.CommandLine$Model$CommandReflection.extractCommandSpec(CommandLine.java:10597)
              at groovyjarjarpicocli.CommandLine$Model$CommandSpec.forAnnotatedObject(CommandLine.java:5765)
              at groovyjarjarpicocli.CommandLine.<init>(CommandLine.java:223)
              at groovyjarjarpicocli.CommandLine.<init>(CommandLine.java:196)
              at groovy.ui.GroovyMain.processArgs(GroovyMain.java:128) 

      Attachments

        Activity

          People

            paulk Paul King
            paulk Paul King
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: