Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Null pointer exception executing java-generator-cli #4534

Closed
andreaTP opened this issue Oct 26, 2022 · 4 comments · Fixed by #4537
Closed

Null pointer exception executing java-generator-cli #4534

andreaTP opened this issue Oct 26, 2022 · 4 comments · Fixed by #4537
Assignees
Labels
Milestone

Comments

@andreaTP
Copy link
Member

andreaTP commented Oct 26, 2022

Describe the bug

java-generator-cli artifact is causing a NullPointerException when executed via jbang (I haven't tested yet other configurations).

Fabric8 Kubernetes Client version

6.2.0

Steps to reproduce

jbang io.fabric8:java-generator-cli:6.2.0 -s java-generator/core/src/test/resources/crontab-crd.yml -t ./tmp

Expected behavior

The java classes are correctly generated.

Runtime

other (please specify in additional context)

Kubernetes API Server version

1.25.3@latest

Environment

macOS

Fabric8 Kubernetes Client Logs

java.lang.NullPointerException
        at io.fabric8.java.generator.cli.GenerateJavaSources.run(GenerateJavaSources.java:74)
        at picocli.CommandLine.executeUserObject(CommandLine.java:1939)
        at picocli.CommandLine.executeHelpRequest(CommandLine.java:1929)
        at picocli.CommandLine.executeHelpRequest(CommandLine.java:1909)
        at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2176)
        at picocli.CommandLine$RunLast.execute(CommandLine.java:2316)
        at picocli.CommandLine.execute(CommandLine.java:2078)
        at io.fabric8.java.generator.cli.GenerateJavaSources.main(GenerateJavaSources.java:80)

Additional context

No response

@andreaTP
Copy link
Member Author

cc. @manusa if something in the dependencies might have caused this to happen ...

@andreaTP
Copy link
Member Author

cc. @remkop if you have something on top of your head, but the picocli version remained stable ...

@andreaTP andreaTP changed the title Null pointer exception executing java-generator-cli through jbang Null pointer exception executing java-generator-cli Oct 26, 2022
@remkop
Copy link

remkop commented Oct 27, 2022

Perhaps you can get more details with picocli's tracing function.

https://picocli.info/#_tracing

@manusa
Copy link
Member

manusa commented Oct 27, 2022

cc. @manusa if something in the dependencies might have caused this to happen ...

I need to check, I didn't even remember we had this (running cli through JBang) as a feature.
We should probably create an IT to make sure it doesn't beak again once we fix it.

@manusa manusa added the bug label Nov 4, 2022
@manusa manusa added this to the 6.3.0 milestone Nov 4, 2022
manusa added a commit that referenced this issue Nov 4, 2022
Signed-off-by: Marc Nuri <marc@marcnuri.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants