OpenConext / Mujina

A mock IDP and SP using the OpenSAML library
Apache License 2.0
369 stars 166 forks source link

Getting compile errors when downloading fresh copy #21

Closed jackmatt2 closed 7 years ago

jackmatt2 commented 7 years ago

git clone https://github.com/OpenConext/Mujina.git cd Mujina/ git checkout mujina-5.0.5 mvn clean install

[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] mujina ............................................. SUCCESS [  1.057 s]
[INFO] mujina-common ...................................... SUCCESS [  2.752 s]
[INFO] mujina-sp .......................................... FAILURE [  1.684 s]
[INFO] mujina-idp ......................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.017 s
[INFO] Finished at: 2017-05-29T17:48:53+10:00
[INFO] Final Memory: 53M/484M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (default-testCompile) on project mujina-sp: Compilation failure: Compilation failure:
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/AbstractIntegrationTest.java:[25,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/AbstractIntegrationTest.java:[25,1] static import only from classes and interfaces
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/AbstractIntegrationTest.java:[26,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/AbstractIntegrationTest.java:[26,1] static import only from classes and interfaces
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/MetadataEndPointTest.java:[9,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/MetadataEndPointTest.java:[9,1] static import only from classes and interfaces
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/api/SpControllerTest.java:[7,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/api/SpControllerTest.java:[7,1] static import only from classes and interfaces
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/UserControllerTest.java:[10,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/UserControllerTest.java:[10,1] static import only from classes and interfaces
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/UserControllerTest.java:[11,30] package org.apache.http does not exist
[ERROR] /Users/********/git/Mujina/mujina-sp/src/test/java/mujina/sp/UserControllerTest.java:[11,1] static import only from classes and interfaces
[ERROR] -> [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/MojoFailureException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <goals> -rf :mujina-sp

Appears that apache HttpClient is not downloading for some reason.

oharsta commented 7 years ago

I can not reproduce this on my local machine:

okke@honderdnegenenvijftig projects $ git clone https://github.com/OpenConext/Mujina.git Mujina-reproduce-issue-21
Cloning into 'Mujina-reproduce-issue-21'...
remote: Counting objects: 4696, done.
remote: Total 4696 (delta 0), reused 0 (delta 0), pack-reused 4696
Receiving objects: 100% (4696/4696), 1.12 MiB | 734.00 KiB/s, done.
Resolving deltas: 100% (1659/1659), done.
okke@honderdnegenenvijftig projects $ cd Mujina-reproduce-issue-21/
okke@honderdnegenenvijftig Mujina-reproduce-issue-21 (master)$ git checkout mujina-5.0.
mujina-5.0.0   mujina-5.0.5   
okke@honderdnegenenvijftig Mujina-reproduce-issue-21 (master)$ git checkout mujina-5.0.5
Note: checking out 'mujina-5.0.5'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

HEAD is now at 8b3f474... Release 5.0.5
okke@honderdnegenenvijftig Mujina-reproduce-issue-21 (detached*)$ mvn clean install > /tmp/output-clean-install-issue-21.txt
okke@honderdnegenenvijftig Mujina-reproduce-issue-21 (detached*)$ tail -20 /tmp/output-clean-install-issue-21.txt
[INFO] 
[INFO] --- spring-boot-maven-plugin:1.5.2.RELEASE:repackage (default) @ mujina-idp ---
[INFO] 
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ mujina-idp ---
[INFO] Installing /Users/okke/projects/Mujina-reproduce-issue-21/mujina-idp/target/mujina-idp-5.0.5.jar to /Users/okke/.m2/repository/org/openconext/mujina-idp/5.0.5/mujina-idp-5.0.5.jar
[INFO] Installing /Users/okke/projects/Mujina-reproduce-issue-21/mujina-idp/pom.xml to /Users/okke/.m2/repository/org/openconext/mujina-idp/5.0.5/mujina-idp-5.0.5.pom
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] mujina ............................................. SUCCESS [  0.759 s]
[INFO] mujina-common ...................................... SUCCESS [  1.626 s]
[INFO] mujina-sp .......................................... SUCCESS [ 13.855 s]
[INFO] mujina-idp ......................................... SUCCESS [ 12.959 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 29.489 s
[INFO] Finished at: 2017-05-29T13:31:55+02:00
[INFO] Final Memory: 50M/236M
[INFO] ------------------------------------------------------------------------
okke@honderdnegenenvijftig Mujina-reproduce-issue-21 (detached*)$ 

Can you attach / post the entire output of your build?

jackmatt2 commented 7 years ago

Turns out my .m2 had a bad pom file. I needed to delete ~/.m2/repository/org/apache/httpcomponents/project/7/