exceptionless / Exceptionless.Java

Exceptionless Java client
Apache License 2.0
6 stars 2 forks source link

Unable to build or run tests #34

Closed niemyjski closed 3 years ago

niemyjski commented 3 years ago

I installed latest JDK 11 (not the OJDK) and maven latest and I can't verify or run any of the tests. Is there something I need to do? I can't verify or click around in VS Code very easily because the builder methods don't exist.

> Executing task: mvn -B verify <

[INFO] Scanning for projects...
[INFO]
[INFO] ---------------< com.exceptionless:exceptionless-client >---------------
[INFO] Building exceptionless-client 1.0-beta1
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.22.0/maven-surefire-plugin-2.22.0.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.22.0/maven-surefire-plugin-2.22.0.pom (5.0 kB at 15 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/surefire/surefire/2.22.0/surefire-2.22.0.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/surefire/surefire/2.22.0/surefire-2.22.0.pom (27 kB at 414 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/31/maven-parent-31.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/maven-parent/31/maven-parent-31.pom (43 kB at 723 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/apache/19/apache-19.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/apache/19/apache-19.pom (15 kB at 298 kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-jar-plugin/2.4/maven-jar-plugin-2.4.pom (5.8 kB at 102 
kB/s)
[INFO] Downloading from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom
[INFO] Downloaded from central: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-plugins/22/maven-plugins-22.pom (13 kB at 256 kB/s)
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ exceptionless-client ---
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory D:\Code\Exceptionless.Java\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.5.1:compile (default-compile) @ exceptionless-client ---
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding Cp1252, i.e. build is platform dependent!
[INFO] Compiling 78 source files to D:\Code\Exceptionless.Java\target\classes
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  1.662 s
[INFO] Finished at: 2021-04-18T08:39:04-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile (default-compile) on project exceptionless-client: Fatal error 
compiling: invalid target release: 11 -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
The terminal process "C:\WINDOWS\System32\WindowsPowerShell\v1.0\powershell.exe -Command mvn -B verify" terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.
pc9795 commented 3 years ago

I have used Lombok for the automatic generation of lots of Java code. IntelliJ provides code completion if you use lombok. Maybe there is some extension for VSCode. I will import this project in VSCode and will have a look

pc9795 commented 3 years ago

mvn clean verify should do the trick but yeah let me have a look

github-actions[bot] commented 3 years ago

This issue is stale

pc9795 commented 3 years ago

invalid target release: 11 This looks like the Java version is not set properly. Maybe some hints here: https://stackoverflow.com/questions/51468580/maven-invalid-target-release-10

For VSCode code completion using Lombok, I will suggest this extension: https://marketplace.visualstudio.com/items?itemName=GabrielBB.vscode-lombok. I have updated this info in readme too