You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Upgraded my project to the use "execute" commandline and it works, but I get some warnings in the beginning.
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by picocli.CommandLine$Help$Ansi (file:/C:/Users/.../ext/picocli/picocli.jar) to field java.io.FilterOutputStream.out
WARNING: Please consider reporting this to the maintainers of picocli.CommandLine$Help$Ansi
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
For reference:
openjdk 11.0.2 2019-01-15
OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.2+9)
OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.2+9, mixed mode)
With jdk1.8.0_181 in eclipse these warnings do not show up!
publicclassToolimplementsRunnable {
@Option(names = { "-h", "--help" }, usageHelp = true, description = "Display this help message")
privatebooleanusageHelpRequested = false;
@Option(names = { "-v", "--verbose" }, description = { "Enable verbose output" })
booleanverboseMode = false;
publicvoidrun() {
...
}
publicstaticvoidmain(String[] args) {
// Prepare PrintWriter with auto-flush optionPrintWriterout = newPrintWriter(System.out, true);
PrintWritererr = newPrintWriter(System.err, true);
// ColorScheme auto-detection of ANSI terminalsAnsiansi = Help.Ansi.AUTO;
CommandLinecmd = newCommandLine(newTool())
// set output
.setOut(out).setErr(err)
// disable clustering support for short options (e.g. -hv)
.setPosixClusteredShortOptionsAllowed(false)
// set color scheme
.setColorScheme(Help.defaultColorScheme(ansi));
// Register default result handler and default exception handler.intexitCode = cmd.execute(args);
System.exit(exitCode);
}
}
Thank you for providing this great framework.
The text was updated successfully, but these errors were encountered:
Mhh, the warnings came up on a windows machine. I tried to reproduce the issue on a linux machine but the warnings didn't came up. The linux machine has
openjdk 11.0.3 2019-04-16
OpenJDK Runtime Environment (build 11.0.3+7-Ubuntu-1ubuntu218.04.1)
OpenJDK 64-Bit Server VM (build 11.0.3+7-Ubuntu-1ubuntu218.04.1, mixed mode, sharing)
I don't want to downgrade, but I can try to upgrade the windows machine to the latest AdoptOpenJDK 11 release if it helps.
Upgraded my project to the use "execute" commandline and it works, but I get some warnings in the beginning.
For reference:
With jdk1.8.0_181 in eclipse these warnings do not show up!
Thank you for providing this great framework.
The text was updated successfully, but these errors were encountered: