SpencerPark / IJava

A Jupyter kernel for executing Java code.
MIT License
1.09k stars 212 forks source link

Unresolved dependency and Server access error, InvalidAlgorithmParameterException #112

Open shawnw19 opened 3 years ago

shawnw19 commented 3 years ago

The problem I met happened in Maven resolution, which is similar to https://github.com/SpencerPark/IJava/issues/32 .

For %maven org.knowm.xchart:xchart:3.5.2, the error is:

---------------------------------------------------------------------------
java.lang.RuntimeException: Exception occurred while running line magic 'maven': Error resolving 'org.knowm.xchart:xchart:3.5.2'. [unresolved dependency: org.knowm.xchart#xchart;3.5.2: not found, unresolved dependency: org.knowm.xchart#xchart;3.5.2: not found]
    at io.github.spencerpark.ijava.runtime.Magics.lineMagic(Magics.java:19)
    at .(#19:1)

And for %maven org.apache.commons:commons-math3:3.6.1 , the error is:

:: problems summary ::
:::: ERRORS
    Server access error at url https://repo.maven.apache.org/maven2/org/apache/commons/commons-math3/3.6.1/commons-math3-3.6.1.pom (javax.net.ssl.SSLException: java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty)

    Server access error at url https://repo.maven.apache.org/maven2/org/apache/commons/commons-math3/3.6.1/commons-math3-3.6.1.jar (javax.net.ssl.SSLException: java.lang.RuntimeException: Unexpected error: java.security.InvalidAlgorithmParameterException: the trustAnchors parameter must be non-empty)

---------------------------------------------------------------------------
java.lang.RuntimeException: Exception occurred while running line magic 'maven': Error resolving 'org.apache.commons:commons-math3:3.6.1'. [unresolved dependency: org.apache.commons#commons-math3;3.6.1: not found, unresolved dependency: org.apache.commons#commons-math3;3.6.1: not found]
    at io.github.spencerpark.ijava.runtime.Magics.lineMagic(Magics.java:19)
    at .(#18:1)

The second type of error also happens in things like

%%loadFromPOM
<dependency>
    <groupId>org.deeplearning4j</groupId>
    <artifactId>deeplearning4j-core</artifactId>
    <version>1.0.0-beta4</version>
</dependency>

I tried some solutions in stackoverflow targeted for same exception and errors (like this ) but failed.

For your information, the Jupyter was installed separately without Anaconda. The version of Java is 10.

Thank you very much in advance for your help.

AndrewProgramming commented 3 years ago

this is because the repository cannot be visited. so I think you should update your repository or change another repository