Trying to debug some client/designer scope module stuff, and I've been working on getting Intellij set up for a bit but i've gotten stuck with this pesky error when trying to run the configuration as it is on the SDK dev guide:
Exception in thread "main" java.lang.NullPointerException: Cannot invoke "java.lang.CharSequence.length()" because "this.text" is null
It seems to be something with parsing the Gateway address from one of the JVM arguments. I've got the same ones as on the SDK guide, I've tried fiddling with it yet cant get anything to work, always the same error.
Anyone have experience with this issue?
Can you screenshot your launch config including those args?
Also not sure it matters, but you should be using JDK 11, not whatever newer version you have configured.
I switched from 20 to JDK 11, didnt change anything.
Heres the config:
I realized that this was from trying some other configs from another forum post, but that was because when trying to run the config from the SDK page:
it gives the error:
Launch parameter "javaws.sr.main" missing.
same error on both, also the target VM address seems to be wrong? not sure if thats related. my local gateway is at http://localhost:8088/
Hmm, this NPE is happening because the
sr.gateway property isn't being found. If you copied my args and put them into the correct spot in the launch dialog I'm not sure why else that would happen.
Are you sure you're putting them into the JVM Args (VM Options) section and not the Program Arguments section?
oh, yep, that might be it
ah, its because intellij hid the VM arguments since they were blank that I couldnt even see the option
Yeah, IntelliJ's refactor of the run configuration dialog is a big miss in my opinion.
yeah big miss.
I did try putting arguments there, and have tried a whole bunch of different configurations and everything from this thread: Ignition 8 Designer Debugging not working - Module Development - Inductive Automation Forum. Still getting version mismatch
Can you show the full details of whatever error you're getting? The version=dev should prevent a version mismatch.
Ah yes that was the missing piece, sorry about that. Finally it works somewhat. Thank you so much for the help!
Its able to open, but missing the Perspective module and the module im trying to use, I think that is a dependency issue in the pom of the designer-launcher
Hopefully that wont be too hard to fix