Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

'dependencies.dependency.version' for org.slf4j:slf4j-jcl:jar is missing

Tags:

java

github

maven

I was trying to import most of maven based project from the Github repository and once I imported all the projects, this is what I am seeing on my console -

Project build error: 'dependencies.dependency.version' for org.slf4j:slf4j-jcl:jar is missing.  pom.xml /testdemo   line 23 Maven pom Loading Problem
Project build error: 'dependencies.dependency.version' for org.slf4j:slf4j-api:jar is missing.  pom.xml /testdemo   line 28 Maven pom Loading Problem
null (org.apache.maven.plugins:maven-resources-plugin:2.5:resources:default-resources:process-resources)    pom.xml /testdemo   line 3  Maven Build Problem
null (org.apache.maven.plugins:maven-resources-plugin:2.5:testResources:default-testResources:process-test-resources)   pom.xml /testdemo   line 3  Maven Build Problem

There is some error complaining about org.slf4j:slf4j-jcl:jar missing.

I am not sure how to fix this issue? Any thoughts?

This is what in my pom.xml file -

<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-jcl</artifactId>
</dependency>

<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-api</artifactId>
</dependency>
like image 934
AKIWEB Avatar asked Dec 08 '22 10:12

AKIWEB


2 Answers

Version of the library is missing, try this:

<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-jcl</artifactId>
    <version>1.7.5</version>
</dependency>     
<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-api</artifactId>
    <version>1.7.5</version>
</dependency>
like image 75
Marcin Krupa Avatar answered Feb 13 '23 05:02

Marcin Krupa


You're missing the <version> tag from your <dependency> block.

For example:

<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-jcl</artifactId>
    <version>1.1.1</version>
</dependency>
like image 43
bn. Avatar answered Feb 13 '23 05:02

bn.