When I try to connect API keys to a given app, the app crashes and I get the following error:
java.lang.reflect.InaccessibleObjectException: Unable to make field private static volatile java.net.Authenticator java.net.Authenticator.theAuthenticator accessible: module java.base does not "opens java.net" to unnamed module @6f1eab88
I now realize that I need to "build a specific binary (JAR) for my platform." I have been trying for a couple hours but truthfully have no idea what to do. Any help would be appreciated.
Specs:
MacOS Big Sur v11.6.8
Java v17.0.5
Gradle v7.6
Homebrew v3.6.16
GitHub link to project: https://github.com/quantverse/ptltrader
Instructions for building are in the "README.md" file.
I normally run the JAR file via terminal and it works fine until I try connecting to the website via API, at which point the app crashes. When I try to run any Gradle functions, nothing works because it's a JAR file.
I downloaded the .zip file and tried to run Gradle again but got several errors. I believe these are due to the code being written in 2012 and therefore being outdated. After replacing a couple lines of code as recommended by stackoverflow (such as "testImplementation" instead of "testCompile," and "doLast" instead of "<<"), I try running gradle ./gradlew run
as recommended by the source code, and get the following error:
Task './gradlew' not found in root project 'PTLTrader'.
When I try gradle run
, I get the following error:
> Process 'command '/usr/local/Cellar/openjdk@17/17.0.5/libexec/openjdk.jdk/Contents/Home/bin/java'' finished with non-zero exit value 1
At this point, I gave up because I did not know what else I could do. I tried moving the JAR file into the directory to run it with the rest of the zip file, but the same error/inability to connect to website API occurred.