-
Notifications
You must be signed in to change notification settings - Fork 334
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Maven build problem #273
Comments
Thanks for reporting, @BarchSteel! I cannot reproduce with my local clone, building with Maven 3.3.9 and Java 1.8.0_271 on Mac OSX, using:
You can skip tests by running:
Please note however that it shouldn't be necessary at all for you to build this project. If you want to test modifications in any specific component (such as You can have Maven copy the jars and all dependencies by using:
|
Thank you for the answer. The problem is reproducible for me. I also tested on a different PC (also Windows 10, x64, same Eclipse Version), and the error is identical. But your trick: -DskipTests worked! I created the .jar. (I entered it as "goal" in the menu for Run As->"2 Maven build..." and it seemed to work.) I wanted to debug my changes in scifio, but I could not get the debugger to work correctly on my setup, unless I had both ImageJ and SCIFIO as projects set up. I also needed to disable the default SCIFIO dependency in the ImageJ project and manually add my scifio project to the class-path. The reason that I could not copy over the sicfio.jar was, because building scifio.jar using the maven build process, also fails during the test, but of course with different code lines (I made a forum post for this, in case others struggle in the same way: https://forum.image.sc/t/trouble-compiling-scifio-from-git-repository/46695) |
Looks like in both cases the services are not discovered (based on the forum post, the SCIFIO NullPointerException during the tests is thrown here). Running |
I set up a test build using the GitHub actions workflow to compile imagej on windows-latest and there it works without problems: So the problem lies on my PC, either with Eclipse, or the JDK. |
There is a longstanding bug in the @BarchSteel I'm not certain your problem is the same as this, but I am quite suspicious. 😉 It is unfortunate that we need this |
I installed the apache-maven-3.6.3 and used it on the command line in the ImageJ source directory. The solution was to delete the complete So this is not a maven problem, but an Eclipse IDE problem. I was looking around to find this Just out of curiosity: How is scijava-maven-plugin referenced from imagej pom.xml? It seems the dependency goes like this: |
This issue has been mentioned on Image.sc Forum. There might be relevant details there: https://forum.image.sc/t/trouble-compiling-scifio-from-git-repository/46695/2 |
The |
Hello,
I set up Eclipse, JDK8, cloned imagej/imagej, imported the project -> everything OK.
I can also start & debug ImageJ 2.1.1-snapshot from with Eclipse. (go to net.imagej->main.java and Run As->Java App)
But I can't get the maven build to succeed to build the package or do an install.
It will fail during the tests.
What can I do to skip the tests? What is my mistake, so that I can build the package, or do a maven install?
My goal is to create and test a stand-alone version for testing my modifications.
The text was updated successfully, but these errors were encountered: