remkop / picocli

Picocli is a modern framework for building powerful, user-friendly, GraalVM-enabled command line apps with ease. It supports colors, autocompletion, subcommands, and more. In 1 source file so apps can include as source & avoid adding a dependency. Written in Java, usable from Groovy, Kotlin, Scala, etc.

Home Page:https://picocli.info

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ManPageGenerator fails with Quarkus

svartkanin opened this issue · comments

I'm using picocli successfully with Quarkus but now wanted to use the ManPageGenerator command as well.

@Command(
    name = "documentation",
    description = ["Command to generate CLI documentation"],
    subcommands = [ ManPageGenerator::class]
)
class Documentation

However, running building the executable and running it leads to the error

 ERROR [io.qua.run.Application] (main) Failed to start application (with profile [prod]): picocli.CommandLine$InitializationException: Could not access or modify mixin member picocli.codegen.docgen.manpage.ManPageGenerator$Config picocli.codegen.docgen.manpage.ManPageGenerator.config: java.lang.NoSuchMethodException: picocli.codegen.docgen.manpage.ManPageGenerator$Config.<init>()
   at picocli.CommandLine$Model$CommandReflection.buildMixinForMember(CommandLine.java:12055)
   at picocli.CommandLine$Model$CommandReflection.initFromAnnotatedTypedMembers(CommandLine.java:11930)
   at picocli.CommandLine$Model$CommandReflection.initFromAnnotatedMembers(CommandLine.java:11909)
   at picocli.CommandLine$Model$CommandReflection.extractCommandSpec(CommandLine.java:11842)
   at picocli.CommandLine$Model$CommandSpec.forAnnotatedObject(CommandLine.java:6388)
   at picocli.CommandLine.<init>(CommandLine.java:230)
   at picocli.CommandLine.toCommandLine(CommandLine.java:3631)
   at picocli.CommandLine.access$16700(CommandLine.java:148)
   at picocli.CommandLine$Model$CommandReflection.initSubcommands(CommandLine.java:11874)
   at picocli.CommandLine$Model$CommandReflection.extractCommandSpec(CommandLine.java:11840)
   at picocli.CommandLine$Model$CommandSpec.forAnnotatedObject(CommandLine.java:6388)
   at picocli.CommandLine.<init>(CommandLine.java:230)
   at picocli.CommandLine.toCommandLine(CommandLine.java:3631)
   at picocli.CommandLine.access$16700(CommandLine.java:148)
   at picocli.CommandLine$Model$CommandReflection.initSubcommands(CommandLine.java:11874)
   at picocli.CommandLine$Model$CommandReflection.extractCommandSpec(CommandLine.java:11840)
   at picocli.CommandLine$Model$CommandSpec.forAnnotatedObject(CommandLine.java:6388)
   at picocli.CommandLine.<init>(CommandLine.java:230)
   at picocli.CommandLine.<init>(CommandLine.java:224)
   at io.quarkus.runtime.ApplicationLifecycleManager.run(ApplicationLifecycleManager.java:132)
   at io.quarkus.runtime.Quarkus.run(Quarkus.java:71)
   at io.quarkus.runtime.Quarkus.run(Quarkus.java:44)
   at io.quarkus.runner.GeneratedMain.main(Unknown Source)

Sorry I dropped the ball on this...
I just created a test without Quarkus, that seems to work fine.
This seems to be a Quarkus issue. Have you asked the Quarkus maintainers about this issue?