This error won't go away even after many 'mvn clean install' and reimport pom.xml's
[ERROR] Failed to execute goal on project foo:
Could not resolve dependencies for project be.foo:foo:jar:2.0-SNAPSHOT:
The following artifacts could not be resolved:
org.neo4j:neo4j-spatial:jar:0.12-neo4j-2.0.4,
diff_match_patch:diff_match_patch:jar:current:
Failure to find org.neo4j:neo4j-spatial:jar:0.12-neo4j-2.0.4 in
https://repo.spring.io/libs-release was cached in the local repository,
resolution will not be reattempted until the update interval of spring-releases has elapsed or updates are forced -> [Help 1]
eventhough the pom clearly has the dependency:
<dependency>
<groupId>org.neo4j</groupId>
<artifactId>neo4j-spatial</artifactId>
<version>0.12-neo4j-2.0.4</version>
</dependency>
Weirdest thing is I don't even think I need this in my project, it just started complaining about it.
So far I'm guessing that it has to do with some sort of version mismatch?
"diff_match_patch" etc
If you go to the URL thart´s shown in your logs, you´ll see that library is not there. You probably need to change the version or set up a different repo.
Related
I am currently trying to follow this guide and every time I try to run the test code I am getting this error:
[ERROR] Failed to execute goal on project MyBot: Could not resolve
dependencies for project org.example:MyBot:jar:1.0-SNAPSHOT:
org.javacord:javacord:jar:3.4.0 was not found in
https://repo.maven.apache.org/maven2 during a previous attempt. This
failure was cached in the local repository and resolution is not
reattempted until the update interval of central has elapsed or
updates are forced -> [Help 1]
pom.xml
Maybe you have to load the dependencies you added to the pom.xml.
in IntelliJ you can right click on your pom.xml chose maven -> reload Project.
This loads all dependencies from pom.xml.
Check the console output for any errors.
Should the answer from Kaspatoo not working for you you can try to add the repository from Javacord to your project.
I figured it out, maven had downloaded the jars for the Dependency but wasn't loading them, I pointed maven to them in the system directory, and its working now
I am following this tutorial. Also, on my local machine I have two Maven projects; let's call them:
MyAppDAO (contains all database related code),
MyAppWorker (performs the background tasks on the database).
The relationship between the two is that MyAppWorker includes MyAppDAO as a Maven dependency so that it can work with the database; in the pom.xml of MyAppWorker I have
<dependencies>
...
<dependency>
<groupId>com.someone.myapp</groupId>
<artifactId>MyAppDAO</artifactId>
<version>1.0</version>
</dependency>
...
</dependencies>
I was able to make it work locally, yet whenever I try to push MyAppWorker to Heroku, I get:
[ERROR] Failed to execute goal on project MyAppWorker: Could not resolve dependencies for project com.someone.myapp:MyAppWorker:jar:1.0: Could not find artifact com.someone:MyAppDAO:jar:1.0 in central (https://repo.maven.apache.org/maven2) -> [Help 1]
My best guess is that I have to tell Maven not to search MyAppDAO at https://repo.maven.apache.org/maven2 but to look at the <project_folder>/target/dependency, yet I did not find any helpful information on how to resolve the issue assuming my guess is correct in the first place.
Following these instructions solved my problem.
I have a maven project from Github, I fork it, and then I imported it to eclipse. It contains three maven modules. I added a fifth one.
Now I want to add this fifth (new) as a dependency to one of the previous modules.
I did the install in maven, and I got the jar located in my local repository. now when I added a dependency to a one of the previous modules, i got error that my new models doesn't exist in the public dependency. I mean:
Failed to execute goal on project moquette-broker: Could not resolve dependencies for project org.eclipse.moquette:moquette-broker:jar:0.7: Failure to find org.eclipse.moquette:moquette-configurationmanager:jar:0.7 in https://repo.eclipse.org/content/repositories/paho-releases/ was cached in the local repository, resolution will not be reattempted until the update interval of Paho Releases has elapsed or updates are forced -> [Help 1]
my question is how can I tell eclipse to search in my local repository as well?
I tried to upload my dependency to a public repository but it doesn't make any sence now because i am still developing
could you help please
the jar in my local repository
this is what i put in the pom in order to call my new module
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>moquette-configurationmanager</artifactId>
<version>${project.version}</version>
<scope>Test</scope>
</dependency>
and the image that i published is my local repository, because i can see that from my eclipse, like this:
After reading the first 28 comments and responses to your question, I still cannot imagine the cause of this strange error, so you'll have to debug it a bit more:
Two recommendations to debug the Maven build:
Whatever test you run, execute mvn --debug <phase> and analyze carefully the produced log.
Run mvn dependency:build-classpath to ask Maven where are the downloaded libraries referenced in the classpath.
I am trying to build a project which has a following dependency
<dependency>
<groupId>org.richfaces.examples</groupId>
<artifactId>richfaces-showcase</artifactId>
<version>4.3.4.Final</version>
<classifier>jbas71</classifier>
<type>war</type>
</dependency>
While the WAR file seems to be on the right place in my local repo. Contents of .m2/repository/org/richfaces/examples/richfaces-showcase/4.3.4.Final/
richfaces-showcase-4.3.4.Final-jbas71.war
richfaces-showcase-4.3.4.Final-jbas71.war.lastUpdated
richfaces-showcase-4.3.4.Final-jbas71.war.pom
I tried to delete the *.lastUpdated file, *.war.pom seems to be ok too but I am still getting
[ERROR] Failed to execute goal on project richfaces-showcase-portlet:
Could not resolve dependencies for project org.jboss.portletbridge.examples:richfaces-showcase-portlet:war:3.3.1.Final:
Failure to find org.richfaces.examples:richfaces-showcase:war:jbas71:4.3.4.Final in
http://repo.maven.apache.org/maven2 was cached in the local repository, resolution
will not be reattempted until the update interval of central has elapsed or updates are
forced -> [Help 1]
The dependency is imply wrong, cause a war file is not intended to be a dependency. The war file is intended to be use as an example which can be deployed into a Tomcat etc. to see how it looks like etc.
Apart from that you are trying to get richfaces from Maven Central which is not possible cause Richfaces is not in Maven Central. They have their own repository. You need to add this repository to your configuration or Repository manager.
Furthermore the message:
Failure to find org.richfaces.examples:richfaces-showcase:war:jbas71:4.3.4.Final in
http://repo.maven.apache.org/maven2 was cached in the local repository, resolution
will not be reattempted until the update interval of central has elapsed or updates are
forced -> [Help 1]
shows that the dependency couldn't be downloaded. I assume the size of the war file is 0..
I'm new to Maven and JSF and I have the following problem when compiling my project:
Failed to execute goal on project ViewController: Could not resolve dependencies for project com.km.eFarmer:ViewController:war:1.0.1-alpha1-SNAPSHOT: The following artifacts could not be resolved: com.sun.faces:jsf-api:jar:2.0.3-FCS, com.sun.faces:jsf-impl:jar:2.0.3-FCS, org.openfaces:openfaces:jar:3.0.2-KM, cssparser:cssparser:jar:0.9.5, it.eng.spago:sbi-utils:jar:3.3.0: Failure to find com.sun.faces:jsf-api:jar:2.0.3-FCS in http://repo1.maven.org/maven2/ was cached in the local repository, resolution will not be reattempted until the update interval of maven.maven2 has elapsed or updates are forced -> [Help 1
This is means that the artifact com.sun.faces:jsf-api:jar:2.0.3-FCS is absent in repository http://repo1.maven.org/maven2/.
Indeed, there is no jsf-api.jar with version 2.0.3-FCS in this repo.
There's a list of available versions. So, you should change artifact version, or repository url
Simple delete the folder local repository com/sun/faces and and retry it.